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 variable for global flags to runlabel command #2399

Closed
mheon opened this issue Feb 21, 2019 · 6 comments · Fixed by #2905
Closed

Add variable for global flags to runlabel command #2399

mheon opened this issue Feb 21, 2019 · 6 comments · Fixed by #2905
Assignees
Labels
kind/feature Categorizes issue or PR as related to a new feature. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@mheon
Copy link
Member

mheon commented Feb 21, 2019

Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)

/kind feature

Description

We need a variable in podman runlabel labels that expands to global Podman options, so we can pass through configuration (for example, storage config) to Podman commands being executed in labels.

Steps to reproduce the issue:

  1. mkdir /tmp/new

  2. podman --root=/tmp/new create --name test1 -t -i --label 'TEST=podman info'

  3. podman --root=/tmp/new commit test1 testimg

  4. podman --root /tmp/new container runlabel TEST testimg

Describe the results you received:

Podman uses the default storage root

Describe the results you expected:

Podman uses /tmp/new as a storage root

Ideal fix is something like $GLOBAL_OPTS we can throw in the label between podman and info to get the right options in there

@openshift-ci-robot openshift-ci-robot added the kind/feature Categorizes issue or PR as related to a new feature. label Feb 21, 2019
@mheon
Copy link
Member Author

mheon commented Feb 21, 2019

@baude We discussed this via email, but the thread sort of died, so I'm throwing it up here

@rhatdan
Copy link
Member

rhatdan commented Mar 8, 2019

@baude Have you looked at this?
@QiWang19 Could you take a look at this?

@QiWang19
Copy link
Collaborator

@mheon I don't get the picture. Should the output of podman --root /tmp/new container runlabel TEST testimg be GraphRoot: /tmp/new?
like using podman --root=/tmp/new create --name test1 -t -i --label 'TEST=podman --root=/tmp/new info' instead of podman --root=/tmp/new create --name test1 -t -i --label 'TEST=podman info' ?

@mheon
Copy link
Member Author

mheon commented Apr 10, 2019

@QiWang19 runlabel reexecs a new Podman from the label set (TEST). We want to add a flag, say $GLOBAL_OPTS, that we can throw in TEST (for example, TEST=podman $GLOBAL_OPTS info), that expands to any global flags passed to Podman (storage options, log-level, syslog, etc)

@mheon
Copy link
Member Author

mheon commented Apr 10, 2019

Sorry, not a flag - a variable, similar to the other variables in runlabel

@mheon
Copy link
Member Author

mheon commented Apr 10, 2019

Once the variable is added, we then want the output of the last podman runlabel command to reflect the changed global options.

@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 24, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/feature Categorizes issue or PR as related to a new feature. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants