-
Notifications
You must be signed in to change notification settings - Fork 798
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
Test & Doc: buildah-config --port syntax #591
Comments
@TomSweeneyRedHat Could you look into this. |
To give some detail bout the use case. source ./scripts/apline/3.7/h2o/buildah-config.sh
source ./scripts/apline/3.7/consul/buildah-config.sh
source ./scripts/apline/3.7/nomad/buildah-config.sh So in fact all config items can be expected to be set multiple times. What is the defined behavior for each config item, i.e. which are overwritten, which are appended. Hope that makes sense? |
So you are going to call the Options that are a slice should be able to be called multiple times and append while options that are a string/bool will be replaced. We probably should document this in the buildah config help and the man pages. Slices: All others will be replaced. |
[Update 2:] Added behavior the OCI spec v1.0.1 would suggest. Subject to interpretation is indicated with (?). Thanks for considering this use case. I think the most important behavior is that buildah should warn and continue when any config item exists and is being reset (overwritten or appended). I think there is a world of pain ahead if buildah starts promising/trying to catch config errors/inconsistencies. GIGO is likely the best that can be promised/achieved. As to which item is replaced and which is appended. I'll take whatever you decide ;)
I assume the default behavior is "Inform/log and continue", In the CLI I'd reduce these to replace and append. The first column indicates behavior the OCI spec v1.0.1 suggests should be supported.
[1] This is tricky, I can envision use cases where you do want to build up the parameters that are passed to the entry point - concatenate. Other use cases where the parameter handed to the entrypoint should be the last seen (replace). [2] Must follow the annotation rules My 2c. Hope that helps. |
Arises where a container is a composition of several containers. See Buildah issue opencontainers#591 specifically the current use case given in [comment](containers/buildah#591 (comment))
Just getting back to this, buildah config --env a=b |
@taqtiqa-mark Is this still something we should look at? |
Lack of response closing. |
Description
The current tests don't have any tests for port configuration.
This Redhat documentation suggests the syntax for adding a port includes the type decoration
/tcp
# buildah config --port 80/tcp working-container
The current documentation is ambiguous.
It is also not documented how to add multiple ports some with different types, e.g. tcp or udp.
The text was updated successfully, but these errors were encountered: