-
Notifications
You must be signed in to change notification settings - Fork 770
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
vendor in latest runtime-tools #828
Conversation
if err != nil { | ||
return options, err | ||
} | ||
spec := g.Config |
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: This is fine, but you may want to consider renaming spec
-> config
as well. I don't know why the runtime-spec authors decided to use Spec
for the structure backing config.json
, but that JSON is a configuration based on a specification, not a specification in its own right (also why the file is not specification.json
;).
@@ -177,8 +177,11 @@ func DefaultNamespaceOptions() NamespaceOptions { | |||
{Name: string(specs.UserNamespace), Host: true}, | |||
{Name: string(specs.UTSNamespace), Host: true}, | |||
} | |||
g := generate.New() | |||
spec := g.Spec() | |||
g, err := generate.New("linux") |
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'm fine with hard-coding this here, because any cross-platform buildah implementation would have to switch OSes at a higher level, and only call DefaultNamespaceOptions
on Linux (since that function makes no sense on other OSes).
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.
Right, thats the conclusion I came to as well
The latest runtime-tools is aware of other OS's than Linux. Libpod needs the newer version to compile on darwin. Unfortunately, the API for generator.New() changed and requires a string representation of the OS; furthermore, it also returns a a generator and an error so code had to be adjusted for this too. Signed-off-by: baude <bbaude@redhat.com>
dae3956
to
b599244
Compare
LGTM and happy green test buttons |
📌 Commit b599244 has been approved by |
The latest runtime-tools is aware of other OS's than Linux. Libpod needs the newer version to compile on darwin. Unfortunately, the API for generator.New() changed and requires a string representation of the OS; furthermore, it also returns a a generator and an error so code had to be adjusted for this too. Signed-off-by: baude <bbaude@redhat.com> Closes: #828 Approved by: rhatdan
💔 Test failed - status-papr |
Seems homu is hosed. Merging manually. |
The latest runtime-tools is aware of other OS's than Linux. Libpod needs the newer
version to compile on darwin. Unfortunately, the API for generator.New() changed
and requires a string representation of the OS; furthermore, it also returns a
a generator and an error so code had to be adjusted for this too.
Signed-off-by: baude bbaude@redhat.com