How can i use CodePipeline to build Unity3D application in WebGL format

0

I have created AWS codepipeline for building unity application and also specified buildspec.yml for the same. But facing issue while executing unity commands. Below command I am using.

CMD: xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' /opt/unity/Editor/Unity -quit -batchmode -projectPath . -executeMethod WebGLBuilder.build '${BUILD_OUTPUT_FOLDER}/${BUILD_OUTPUT_NAME} -logfile /dev/stdout'

Error: COMMAND_EXECUTION_ERROR: Error while executing command: eval ${UNITY_COMMAND} -projectPath . -executeMethod WebGLBuilder.build '${BUILD_OUTPUT_FOLDER}/${BUILD_OUTPUT_NAME} -logfile /dev/stdout'. Reason: exit status 1

posta 2 anni fa398 visualizzazioni
1 Risposta
0

Your command has single quotes around some parameter '${BUILD_OUTPUT_FOLDER}/${BUILD_OUTPUT_NAME} -logfile /dev/stdout'.

I assume that you use -logfile options to print unity log into standard output, and use ${BUILD_OUTPUT_FOLDER}/${BUILD_OUTPUT_NAME} to specify the build target path. Then you should use double quotes instead of single quotes (only double quotes translate the variable) and use it only around the build target path so that the command to be like following.

xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' /opt/unity/Editor/Unity -quit -batchmode -projectPath . -executeMethod WebGLBuilder.build "${BUILD_OUTPUT_FOLDER}/${BUILD_OUTPUT_NAME}" -logfile /dev/stdout

AWS
con risposta 2 anni fa
  • Hi Junseong_J, Thank you for your inputs. I have tried with double quotes but the same error it is throwing.

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande