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

Allow configuring app directory/path binaries are placed into #1403

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

Conversation

UnseenWizzard
Copy link

This PR proposes a way to allow optionally modifying under which path binaries are placed inside containers built with ko - as raised in issue #944

Without deeper insight into the code base, this seems like a straightforward addition with limited impact on future maintainability to me - while allowing users migrating to ko to still place binaries in the same location as their previous Docker containers.

Looking forward to your input and any suggestions!

The currently hardcoded 'ko-app' app directory was used as a
hardcoded string in several places in gobuild.
To simplify making it overwritable, all occurances are extraced
into a constant for the default value.
An option is added to overwrite the default /ko-app folder to place app binaries in.
This can be set via cmd line flag or as a default in the config file.
entryPointBasePath string
}

func validateImage(t *testing.T, img oci.SignedImage, baseLayers int64, creationTime v1.Time, opts validationOptions) {
Copy link
Author

Choose a reason for hiding this comment

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

note that baseLayers being 3 in all test uses triggers the linter - as it's unrelated to the change, I didn't want to change the function to appease the linter. lmk if I should

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.

1 participant