-
Notifications
You must be signed in to change notification settings - Fork 4
Create RPC Dockerfile #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I made some small changes to ensure that the correct files are included in the container at build time. Two quick requests: |
I started with trying to get the binary-only Dockerfile first, but it always failed with
This led me down the path of trying to hit your second request to help resolve that using the Dockerfile below:
This one consistently failed with compiler errors. I ran this from my Mac, but was using
This might be another case of Rust skill issues kicking in for me, let me know what you think @crypdoughdoteth. I'll have time to keep poking at it tomorrow. |
That's as far as I made it trying to cross-compile to musl earlier haha. Frankly, the second one is more about finding the right incantations of flags and dependencies in the build step than anything else. I wanted to cross-compile a different project this way half a year ago when I was doing the infrastructure but ran into similar problems. The first iteration will probably work with |
|
The image is building with cross compiling enabled now, but now we're having issues starting the container in our Test action. The debug error logs for that are below:
I confirmed this error isn't being caused by copying the binary to a runtime layer this time either; the latest Dockerfile shows this, and you can see the same error in this run: https://github.com/Developer-DAO/rpc/actions/runs/15740801592/job/44365345739 |
The first line of the main function attempts to load in a .env file and crashes the program otherwise. I'm just going to delete that line |
Basically it's just missing environment variables atm |
Oh duh 🤦🏻♂️ sounds good, next chance I get I'll put the binary back into a new layer and hosted in GHCR so we can pull it locally and test with a DB 🫡 |
@crypdoughdoteth I think this image should be good to go now, it's building successfully and the image is pushed here, tagged based on which branch it was built on: https://github.com/Developer-DAO/rpc/pkgs/container/rpc Pulling this to your Mac will fail since it's only built for |
Changes
extra_hosts
to enable localhost access to DB