From 89484398dc9332e75f3719abc6433e13058cef9d Mon Sep 17 00:00:00 2001 From: Henry Zhang Date: Tue, 19 Jan 2021 15:55:48 -0500 Subject: [PATCH 1/3] try gsutil rsync! --- .gitignore | 1 + cloudbuild.yaml | 27 ++++++++++----------------- test-deploy/dir1/file2 | 0 test-deploy/file1 | 0 4 files changed, 11 insertions(+), 17 deletions(-) create mode 100644 .gitignore create mode 100644 test-deploy/dir1/file2 create mode 100644 test-deploy/file1 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..485dee6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.idea diff --git a/cloudbuild.yaml b/cloudbuild.yaml index 72bf4ac..e73e6f0 100644 --- a/cloudbuild.yaml +++ b/cloudbuild.yaml @@ -1,18 +1,11 @@ -# Copyright 2020 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - steps: -# Build the module. -- name: golang - args: ['go', 'build', '.'] +- name: ubuntu + args: ['bash', '-c', "echo '$COMMIT_SHA' > REVISION.txt"] +- name: gcr.io/cloud-builders/gsutil + args: + - '-m' + - 'rsync' + - '-d' + - '-r' + - 'test-deploy' + - 'gs://${_GCS_BUCKET}/dags/test-deploy' \ No newline at end of file diff --git a/test-deploy/dir1/file2 b/test-deploy/dir1/file2 new file mode 100644 index 0000000..e69de29 diff --git a/test-deploy/file1 b/test-deploy/file1 new file mode 100644 index 0000000..e69de29 From ba4241cf5d0c24d8fcff709fbf8116d6426f5c4d Mon Sep 17 00:00:00 2001 From: Henry Zhang Date: Tue, 19 Jan 2021 16:28:11 -0500 Subject: [PATCH 2/3] hardcode to get it to work first --- cloudbuild.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cloudbuild.yaml b/cloudbuild.yaml index e73e6f0..8df5d89 100644 --- a/cloudbuild.yaml +++ b/cloudbuild.yaml @@ -8,4 +8,4 @@ steps: - '-d' - '-r' - 'test-deploy' - - 'gs://${_GCS_BUCKET}/dags/test-deploy' \ No newline at end of file + - 'gs://rhinodata-test-deploy/dags/test-deploy' \ No newline at end of file From a07ec9560d2d8e53935ecd1e42867fd57b448cf3 Mon Sep 17 00:00:00 2001 From: Henry Zhang Date: Tue, 2 Feb 2021 16:27:42 -0500 Subject: [PATCH 3/3] rename file1 to file2 --- test-deploy/{file1 => file2} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename test-deploy/{file1 => file2} (100%) diff --git a/test-deploy/file1 b/test-deploy/file2 similarity index 100% rename from test-deploy/file1 rename to test-deploy/file2