Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions appengine/storage/flexible/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ Before you can run or deploy the sample, you will need to do the following:
1. Create a Cloud Storage Bucket. You can do this with the [Google Cloud SDK](https://cloud.google.com/sdk)
with the following command:

gsutil mb gs://<your-bucket-name>
gcloud storage buckets create gs://<your-bucket-name>

1. Set the default ACL on your bucket to public read in order to serve files
directly from Cloud Storage. You can do this with the [Google Cloud SDK](https://cloud.google.com/sdk)
with the following command:

gsutil defacl set public-read gs://<your-bucket-name>
gcloud storage buckets update gs://<your-bucket-name> --predefined-default-object-acl=publicRead

1. Update the environment variables in `app.yaml`.

Expand Down
4 changes: 2 additions & 2 deletions appengine/storage/flexible_nodejs16_and_earlier/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ Before you can run or deploy the sample, you will need to do the following:
1. Create a Cloud Storage Bucket. You can do this with the [Google Cloud SDK](https://cloud.google.com/sdk)
with the following command:

gsutil mb gs://<your-bucket-name>
gcloud storage buckets create gs://<your-bucket-name>

1. Set the default ACL on your bucket to public read in order to serve files
directly from Cloud Storage. You can do this with the [Google Cloud SDK](https://cloud.google.com/sdk)
with the following command:

gsutil defacl set public-read gs://<your-bucket-name>
gcloud storage buckets update gs://<your-bucket-name> --predefined-default-object-acl=publicRead

1. Update the environment variables in `app.yaml`.

Expand Down
4 changes: 2 additions & 2 deletions appengine/storage/standard/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ Before you can run or deploy the sample, you will need to do the following:
1. Create a Cloud Storage Bucket. You can do this with the [Google Cloud SDK](https://cloud.google.com/sdk)
with the following command:

gsutil mb gs://<your-bucket-name>
gcloud storage buckets create gs://<your-bucket-name>

1. Set the default ACL on your bucket to public read in order to serve files
directly from Cloud Storage. You can do this with the [Google Cloud SDK](https://cloud.google.com/sdk)
with the following command:

gsutil defacl set public-read gs://<your-bucket-name>
gcloud storage buckets update --predefined-default-object-acl=publicRead gs://<your-bucket-name>

1. Update the environment variables in `app.yaml`.

Expand Down
6 changes: 3 additions & 3 deletions eventarc/audit-storage/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ gcloud run deploy $MY_RUN_SERVICE \
Create a _single region_ Cloud Storage bucket:

```sh
gsutil mb -p $(gcloud config get-value project) \
-l us-central1 \
gcloud storage buckets create --project=$(gcloud config get-value project) \
--location=us-central1 \
gs://"$MY_GCS_BUCKET"
```

Expand All @@ -56,7 +56,7 @@ gcloud beta eventarc triggers create my-gcs-trigger \
Test your Cloud Run service by creating a GCS event:

```sh
gsutil defstorageclass set NEARLINE gs://"$MY_GCS_BUCKET"
gcloud storage buckets update --default-storage-class=NEARLINE gs://"$MY_GCS_BUCKET"
```

Observe the Cloud Run service printing upon receiving an event in Cloud Logging:
Expand Down
4 changes: 2 additions & 2 deletions functions/imagemagick/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ Functions for your project.

1. Create a Cloud Storage Bucket:

gsutil mb gs://YOUR_INPUT_BUCKET_NAME
gcloud storage buckets create gs://YOUR_INPUT_BUCKET_NAME

This storage bucket is used to upload images for the function to check.

1. Create a second Cloud Storage Bucket:

gsutil mb gs://YOUR_OUTPUT_BUCKET_NAME
gcloud storage buckets create gs://YOUR_OUTPUT_BUCKET_NAME

This second storage bucket is used to store blurred images. (Un-blurred images will not be saved to this bucket.)

Expand Down
4 changes: 2 additions & 2 deletions functions/v2/imagemagick/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ Functions for your project.

1. Create a Cloud Storage Bucket:

gsutil mb gs://YOUR_INPUT_BUCKET_NAME
gcloud storage buckets create gs://YOUR_INPUT_BUCKET_NAME

This storage bucket is used to upload images for the function to check.

1. Create a second Cloud Storage Bucket:

gsutil mb gs://YOUR_OUTPUT_BUCKET_NAME
gcloud storage buckets create gs://YOUR_OUTPUT_BUCKET_NAME

This second storage bucket is used to store blurred images. (Un-blurred images will not be saved to this bucket.)

Expand Down
2 changes: 1 addition & 1 deletion memorystore/redis/gce_deployment/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ fi

#Upload the tar to GCS
tar -cvf app.tar -C .. package.json server.js
gsutil cp app.tar gs://"$GCS_BUCKET_NAME"/gce/
gcloud storage cp app.tar gs://"$GCS_BUCKET_NAME"/gce/

# Create an instance
gcloud compute instances create my-instance \
Expand Down
2 changes: 1 addition & 1 deletion memorystore/redis/gce_deployment/startup-script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ apt-get install -yq ca-certificates supervisor nodejs build-essential
curl -s "https://storage.googleapis.com/signals-agents/logging/google-fluentd-install.sh" | bash
service google-fluentd restart &

gsutil cp gs://"$GCS_BUCKET_NAME"/gce/app.tar /app.tar
gcloud storage cp gs://"$GCS_BUCKET_NAME"/gce/app.tar /app.tar
mkdir -p /app
tar -x -f /app.tar -C /app
cd /app
Expand Down
6 changes: 3 additions & 3 deletions run/image-processing/test/e2e_test_cleanup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ steps:
"gcloud pubsub subscriptions delete ${_SERVICE}_sub"

- id: 'Delete GCS buckets'
name: 'gcr.io/cloud-builders/gsutil:latest'
name: 'gcr.io/cloud-builders/gcloud:latest'
entrypoint: /bin/bash
args:
- '-c'
- |
./test/retry.sh "gsutil rm -r gs://${_SERVICE}_input"
./test/retry.sh "gsutil rm -r gs://${_SERVICE}_output"
./test/retry.sh "gcloud storage rm --recursive gs://${_SERVICE}_input"
./test/retry.sh "gcloud storage rm --recursive gs://${_SERVICE}_output"

substitutions:
_SERVICE: image-processing
Expand Down
10 changes: 5 additions & 5 deletions run/image-processing/test/e2e_test_setup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,24 +30,24 @@ steps:
--update-env-vars=BLURRED_BUCKET_NAME=${_SERVICE}_output"

- id: 'Create GCS buckets with Pub/Sub notification'
name: 'gcr.io/cloud-builders/gsutil:latest'
name: 'gcr.io/cloud-builders/gcloud:latest'
entrypoint: /bin/bash
args:
- '-c'
- |
# Create Buckets
./test/retry.sh "gsutil mb -p ${PROJECT_ID} gs://${_SERVICE}_input"
./test/retry.sh "gsutil mb -p ${PROJECT_ID} gs://${_SERVICE}_output"
./test/retry.sh "gcloud storage buckets create --project=${PROJECT_ID} gs://${_SERVICE}_input"
./test/retry.sh "gcloud storage buckets create --project=${PROJECT_ID} gs://${_SERVICE}_output"

# Create Pub/Sub notification
./test/retry.sh "gsutil notification create -t ${_SERVICE} -f json gs://${_SERVICE}_input"
./test/retry.sh "gcloud storage buckets notifications create --topic=${_SERVICE} --payload-format=json gs://${_SERVICE}_input"
./test/retry.sh "gcloud pubsub subscriptions create ${_SERVICE}_sub \
--topic ${_SERVICE} \
--push-endpoint $(gcloud run services describe ${_SERVICE} --project=${PROJECT_ID} --platform=${_PLATFORM} --region=${_REGION} --format='value(status.url)') \
--push-auth-service-account cloud-run-invoker@${PROJECT_ID}.iam.gserviceaccount.com"
sleep 5
# Upload photo
./test/retry.sh "gsutil cp test/zombie.jpg gs://${_SERVICE}_input"
./test/retry.sh "gcloud storage cp test/zombie.jpg gs://${_SERVICE}_input"
sleep 30


Expand Down
Loading