Closed sewah2012 closed 1 year ago
@sewah2012 thanks for reporting this issue. In the book I assume all the examples are run via the Windows Subsystem for Linux, but with small changes you can also run them directly on Windows. I started a new guide with some tips. I hope it will be useful. Any feedback would be much appreciated, thank you!
In particular, if you want to run Tilt from Windows directly, a couple of changes are required to the Tiltfile
:
./gradlew
with gradlew
to run Gradlew from the BAT script$EXPECTED_REF
with %EXPECTED_REF%
to get the value for this environment variable using the Windows syntax.custom_build(
ref = 'catalog-service',
command = 'gradlew bootBuildImage --imageName %EXPECTED_REF%',
deps = ['build.gradle', 'src']
)
Hi, there seems to be an issues with the tilt file in the custom_build part.
The output of the $EXPRECTED_REF seems not to comply with the image name expected for the the OCI image being built with buildPack and as such throws this exception:
STEP 1/3 — Building Custom Build: [config-service] Custom Build: Injecting Environment Variables EXPECTED_REF=config-service:tilt-build-1676992767 EXPECTED_IMAGE=library/config-service EXPECTED_TAG=tilt-build-1676992767 DOCKER_CERT_PATH=C:\Users\emmsewah.minikube\certs DOCKER_HOST=tcp://127.0.0.1:49181 DOCKER_TLS_VERIFY=1 MINIKUBE_ACTIVE_DOCKERD=polar Running cmd: gradlew bootBuildImage --imageName $EXPECTED_REF Starting a Gradle Daemon, 2 busy and 1 incompatible and 1 stopped Daemons could not be reused, use --status for details
FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':bootBuildImage'.
Try:
Get more help at https://help.gradle.org/
BUILD FAILED in 7s 5 actionable tasks: 1 executed, 4 up-to-date gradlew bootBuildImage --imageName $EXPECTED_REF exited with exit code 1
Build Failed: Custom build "gradlew bootBuildImage --imageName $EXPECTED_REF" failed: exit status 1