Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
echo "create iam binding"
gcloud projects add-iam-policy-binding ${GCLOUD_PROJECT} \
--member=serviceAccount:service-${PROJECT_NUMBER} \
echo "create service account"
gcloud iam service-accounts create ${INVOKER_NAME} \
--display-name "Cloud Run Pub/Sub Invoker"
echo "iam roles"
gcloud beta run services add-iam-policy-binding ${PROJECT_NAME} \
--member=serviceAccount:${INVOKER_NAME}@${GCLOUD_PROJECT} \
echo "create subscription"
gcloud beta pubsub subscriptions create ${SUBSCRIPTION_NAME} \
--topic ${TOPIC_NAME} \
--push-endpoint=${SERVICE_URL} \
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.