Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Allow user to write access to gcp dataflow project

Following the quickstart for gcp dataflow here

I run into the following error when executing the example script here

using this command

declare -r PROJECT="beam-test"
declare -r BUCKET="gs://my-beam-test-bucket"

echo
set -v -e

python -m apache_beam.examples.wordcount \
  --project $PROJECT \
  --job_name $PROJECT-wordcount \
  --runner DataflowRunner \
  --staging_location $BUCKET/staging \
  --temp_location $BUCKET/temp \
  --output $BUCKET/output

which results in this error:

 http_response.request_url, method_config, request)
apitools.base.py.exceptions.HttpError: HttpError accessing <https://dataflow.googleapis.com/v1b3/projects/beam-test/locations/us-central1/jobs?alt=json>: response: <{'status': '403', 'content-length': '284', 'x-xss-protection': '1; mode=block', 'x-content-type-options': 'nosniff', 'transfer-encoding': 'chunked', 'vary': 'Origin, X-Origin, Referer', 'server': 'ESF', '-content-encoding': 'gzip', 'cache-control': 'private', 'date': 'Fri, 31 Mar 2017 15:52:54 GMT', 'x-frame-options': 'SAMEORIGIN', 'alt-svc': 'quic=":443"; ma=2592000; v="37,36,35"', 'content-type': 'application/json; charset=UTF-8'}>, content <{
  "error": {
    "code": 403,
    "message": "(f010d95b3e221bbf): Could not create workflow; user does not have write access to project: beam-test Causes: (f010d95b3e221432): Permission 'dataflow.jobs.create' denied on project: 'beam-test'",
    "status": "PERMISSION_DENIED"

I have already enabled the DataFlow api for the project. And I have authorized the gcloud cli with the owner account of the project (which I assumes has full access).

How & where do I enable write permissions?

like image 516
slcott Avatar asked Feb 05 '23 18:02

slcott


1 Answers

Change $PROJECT=project-name to $PROJECT=project-id

like image 126
slcott Avatar answered Feb 13 '23 07:02

slcott