Open fenos opened 2 years ago
Thanks for reporting this issue.
I'm marking this as an enhancement as we don't have direct examples for Google CloudBuild (yet).
I'm unsure why it works with DinD but not was the same image as the runner. Any input on this from the community would be amazing!
Bug description
Context
I'm trying to setup the CI pipeline in Google CloudBuild.
Steps
I've followed carefully all the steps porting the gitlab pipeline example over.
I've generated and activated the license successfully. The generation was done in a CloudBuild runner and the activation manually in the unity website.
I've encoded to base64 the licence and added it as a secret environment variable. Then decoded it before saving it to disk.
Findings
The
before_script.sh
is running fine and writing to disk the licence at:/root/.local/share/unity3d/Unity/Unity_lic.ulf
I've also inspected the licence by
cat /root/.local/share/unity3d/Unity/Unity_lic.ulf
and it matches with the one i've downloaded.The Problem
The problem i'm having is that when the
build.sh
is running it seems that doesn't detect the license file located in/root/.local/share/unity3d/Unity/Unity_lic.ulf
and so it tries to generate a new license to activate.Here is the output I'm getting:
cloud build:
Ugly workaround
If i run the job by using "docker in docker" it seems to work correctly, for example, given the following configuration:
Steps to reproduce
Simply try to run the following job in cloudbuild:
alter the before_script.sh to decode the variable, for example:
Expected behavior
The cloudbuild runner picks up the license when running the
build.sh
scriptAdditional details