Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Cloud Build error: 'Your build failed to run' while using Dockerfile

Hi,

I am using Cloud Run with an automated trigger for Cloud Build (to Github). I am using a Dockerfile for my Cloud build. Everything was working fine, but now I get an error that says I have to update my cloudbuild.yaml file with:

 

options:
  logging: CLOUD_LOGGING_ONLY

 

My problem is that I don't have a cloudbuild.yaml file (or I cannot find it) as I am using a Dockerfile.  How can I fix this?

The error message is:

Your build failed to run: generic::invalid_argument: if 'build.service_account' is specified, the build must either (a) specify 'build.logs_bucket', (b) use the REGIONAL_USER_OWNED_BUCKET build.options.default_logs_bucket_behavior option, or (c) use either CLOUD_LOGGING_ONLY / NONE logging options

Thanks in advance,

Vijay

Solved Solved
0 1 1,329
1 ACCEPTED SOLUTION

Hi, I have solved my problem. After reviewing the logs several times, I discovered that I accidentally moved my requirements.txt file (I am using Python) to another folder. Now it is working fine.

View solution in original post

1 REPLY 1

Hi, I have solved my problem. After reviewing the logs several times, I discovered that I accidentally moved my requirements.txt file (I am using Python) to another folder. Now it is working fine.