Skip to content
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

add documentation for installing custom root ca certificates #1428

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

kosamson
Copy link

Adds a documentation page under the "Advanced" section outlining how to install custom root certificates into a container built using ko.

Discussed initially in #1424 and suggested by @jeffmendoza

adds a documentation page under the advanced section outlining how to
install custom root certificates into a container built using ko
KO_DOCKER_REPO=docker.io/ko-build/static-assets-certs ko build .
```

3. Run the Go application container image with `SSL_CERT_DIR` equal to `/var/run/ko` (the default value for `$KO_DATA_PATH`)
Copy link
Author

@kosamson kosamson Oct 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: I thought of something I might have misunderstood while writing this PR.

Can ko users override the value for KO_DATA_PATH and subsequently where ko will bundle the static assets in the built image? I tried doing this myself and could not override the default path of /var/run/ko on a Linux base image.

After looking at the code I think I understand that this value is statically set, and is abstracted via an environment variable just for the sake of running ko on different operating systems.

Is this correct? If so, I will probably change this example to say

equal to /var/run/ko (the default value for $KO_DATA_PATH on Linux platform images)

Also, if I am correct about the value being statically set per OS, should we clarify the values per OS on the static assets documentation page?

Copy link
Member

@cpanato cpanato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also can use: https:/chainguard-dev/incert after you build your image with ko

@kosamson
Copy link
Author

also can use: https:/chainguard-dev/incert after you build your image with ko

This is really useful, I've never heard about this before. Let me add a section on using this in the new documentation page. This makes building a CI workflow to add the certificates automatically seem really easy.

@kosamson
Copy link
Author

added a section on using incert (thank you for the suggestion @cpanato).

@kosamson kosamson requested a review from cpanato October 19, 2024 01:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants