game-ci / unity-orb

Build and test Unity projects for several platforms using CircleCI.
https://circleci.com/developer/orbs/orb/game-ci/unity
MIT License
7 stars 12 forks source link

Macos-Runner cannot use personal licence #60

Open Yaski opened 9 months ago

Yaski commented 9 months ago

Orb version

game-ci/unity@1.6.0

Execution environment

Bug description

I created personal licence file (Job doesn't run with default licence installed on PC) And I pass licence as base64 encoded file in 'unity-license-var-name'

When I start the job I get the error: "No serial detected. Extracting it from the encoded license. Password: Too long with no output (exceeded 20m0s): context deadline exceeded"

Expected behavior

I expect that job start with licence provided and without error

Yaski commented 9 months ago

I looked at the code and extracted serial code myself. Then passed it in serial variable. But I still get the error: Detected OS: macOS. Detected Unity serial. Password: Too long with no output (exceeded 20m0s): context deadline exceeded

I guess the reason is using commands "sudo mkdir -p "$unity_license_file_path" in prepare-env.sh script So it needs to run from superuser for this commands to work. It is strange because I had licence file installed on PC and I don't need any prepare-env work that is executing each time. Can we have option to disable "prepare-env" step in that case?

Yaski commented 9 months ago

Yes when I changed the daemon to run from 'root' It works ok now. But I am not sure that it is a good idea to run jobs from superuser. At least it is needed only for installing unity and hub and applying licence. It is rare case and can be optimized.