Open marcustut opened 1 year ago
It looks like you are moving the built binary to the current working directory with the initial move but the artifact is expected to reside inside of the trading-api folder so that is probably why it is not found.
Try changing - mv target/release/trading-api bootstrap
to - mv target/release/trading-api trading-api/bootstrap
Hope it helps.
I can't do that actually, it fails on CodeBuild because trading-api
is not a folder there
I'm using Function URLs here, could that be a culprit? I tried running the same build output from CodeBuild on EC2 and I have to use Nginx in order for it to be accessible from he public.
Ok, what if you try.
...
- mv target/release/trading-api bootstrap
...
artifacts:
files:
- bootstrap
I dont use CodeBuild myself but it feels like that should work. I would guess that CodeBuild make anything you specify in the artifacts available somewhere for you to access
Couldn't find valid bootstrap(s): [/var/task/bootstrap /opt/bootstrap] Runtime.InvalidEntrypoint
I'm having this issue after uploading the .zip file that was successfully built by CodeBuild. FYI, I'm using a subdirectory to house my code. So, in CodeBuild I configured the path to be
trading-api/buildspec.yml
. And in the yml file I have to make few changes so that the build pass.Following lines with
<--
shows the changed lines