-
Notifications
You must be signed in to change notification settings - Fork 23
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
build: add Dockerfile for controller, build with bottlerocket-sdk #85
Conversation
a8920a9
to
088a053
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might needs something like this to make TLS implementations (whether OpenSSL or Rustls) happy https://github.com/bottlerocket-os/bottlerocket-ecs-updater/blob/develop/Dockerfile#L34..L35
Obviously merge #84 first, but this looks fine. Thanks!
088a053
to
4e50c4f
Compare
Push above adds the CA certificates store to the container images. |
This seems fine to me after #84 is merged. |
4e50c4f
to
735567f
Compare
Push above rebases onto develop. |
735567f
to
c171147
Compare
Push above changes a few things:
Also removed redundant |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should build an image tagged e.g. bottlerocket-sdk-with-openssl
and then use it in both FROM
lines. This deduplicates the code. I don't think we need to push the tagged image anywhere, but the makefile can ensure that other docker builds depend on it so we know it will be built and available locally.
We might also see if Ben thinks the use case seems likely enough to warrant including musl openssl-devl in the SDK itself, which would be ideal. |
c171147
to
215e8ed
Compare
Push above separates out the openssl musl build into a separate Dockerfile that creates an augmented bottlerocket-sdk with openssl built with the musl toolchain that we use for building the other container images. |
215e8ed
to
94dff77
Compare
Push above changes some Makefile target names as recommended by @webern |
94dff77
to
3de6791
Compare
3de6791
to
cf051f9
Compare
Push above relocates the Images still build fine. |
cf051f9
to
32973dd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🍰
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few nits, but approved 👍
ENV PKG_CONFIG_ALLOW_CROSS=1 | ||
ENV OPENSSL_STATIC=true | ||
ENV OPENSSL_DIR=/musl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Shouldn't ENV
s be closer to ARG
s?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it's absolutely necessary since it's not used for building openssl. These are environment variables we should set after we're able to successfully build openssl with musl. It's intended for building the openssl-sys crate later when we build the controller image. I'll add a comment here to indicate what these environment variables are for.
32973dd
to
a5df576
Compare
Build the binaries with the bottlerocket-sdk. Dockerfile: install openssl with musl for controller, test-agent
Push above and below addresses @arnaldo2792 's comments. Tested the builds and they still work. |
a5df576
to
834f37d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👀
Note: Depends on #84
Issue number:
Closes #11
Description of changes:
Testing done:
Able to build the example-test-agent and the controller and run the binaries with their respective container images.
Terms of contribution:
By submitting this pull request, I agree that this contribution is dual-licensed under the terms of both the Apache License, version 2.0, and the MIT license.