Skip to content

Commit 11a83a8

Browse files
committed
[GHA] GCP Backup upload working
1 parent ff65b39 commit 11a83a8

File tree

2 files changed

+22
-15
lines changed

2 files changed

+22
-15
lines changed

.github/scripts/copy-from-s3-to-gcp.sh

+2-4
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ file_name=${file_name##*/}
99
dir=s3_download_$file_name
1010
mkdir $dir
1111
aws s3 cp $s3_url ./$dir --recursive --no-progress
12-
echo "-------"
1312
ls $dir
14-
echo "-------"
15-
gcloud storage cp $gcp_url ./$dir --recursive
16-
rm -rf dir
13+
echo "gcloud storage cp $gcp_url ./$dir --recursive"
14+
rm -rf $dir

.github/workflows/backup-eclipse-releases-to-gcp.yml

+20-11
Original file line numberDiff line numberDiff line change
@@ -34,16 +34,25 @@ jobs:
3434
with:
3535
sparse-checkout: |
3636
.github/scripts
37-
- name: Download from S3, Upload to GCP
37+
- name: Test
3838
run: |
39-
echo "Copying Eclipse LS extensions ${{ inputs.ls_version }} to GCP..."
40-
url_path=spring-tools/release/TOOLS/sts4-language-server-integrations/${{ inputs.ls_version }}
41-
gcloud storage cp s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path --recursive
42-
43-
echo "Copying Eclipse Distro P2 repos ${{ inputs.ls_version }} to GCP..."
44-
url_path=spring-tools/release/TOOLS/sts4/update/${{ inputs.release_version }}.RELEASE
45-
gcloud storage cp s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path --recursive
39+
echo "Test single file upload"
40+
mkdir contents
41+
echo "Test file" > ./contents/test.txt
42+
gcloud storage cp ./contents gs://gcp-test-spring-io/test.txt --recursive
4643
47-
echo "Copying Eclipse Distros ${{ inputs.release_version }} to GCP..."
48-
url_path=spring-tools/release/STS4/${{ inputs.release_version }}.RELEASE/dist
49-
gcloud storage cp s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path --recursive
44+
url_path=spring-tools/release/STS4/vscode/vscode-spring-boot-1.55.0-RC.1.vsix
45+
${{ github.workspace }}/.github/scripts/copy-from-s3-to-gcp.sh s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path
46+
# - name: Download from S3, Upload to GCP
47+
# run: |
48+
# echo "Copying Eclipse LS extensions ${{ inputs.ls_version }} to GCP..."
49+
# url_path=spring-tools/release/TOOLS/sts4-language-server-integrations/${{ inputs.ls_version }}
50+
# gcloud storage cp s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path --recursive
51+
#
52+
# echo "Copying Eclipse Distro P2 repos ${{ inputs.ls_version }} to GCP..."
53+
# url_path=spring-tools/release/TOOLS/sts4/update/${{ inputs.release_version }}.RELEASE
54+
# gcloud storage cp s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path --recursive
55+
#
56+
# echo "Copying Eclipse Distros ${{ inputs.release_version }} to GCP..."
57+
# url_path=spring-tools/release/STS4/${{ inputs.release_version }}.RELEASE/dist
58+
# gcloud storage cp s3://$AWS_S3_BUCKET/$url_path gs://gcp-test-spring-io/$url_path --recursive

0 commit comments

Comments
 (0)