Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Godeps/Godeps.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion generate/generate.go
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,8 @@ func (g *Generator) SetProcessUsername(username string) {
// SetProcessUmask sets g.Config.Process.User.Umask.
func (g *Generator) SetProcessUmask(umask uint32) {
g.initConfigProcess()
g.Config.Process.User.Umask = umask
u := umask
g.Config.Process.User.Umask = &u
}

// SetProcessGID sets g.Config.Process.User.GID.
Expand Down
2 changes: 1 addition & 1 deletion validate/validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ func JSONSchemaURL(version string) (url string, err error) {
func (v *Validator) CheckJSONSchema() (errs error) {
logrus.Debugf("check JSON schema")

url, err := JSONSchemaURL(v.spec.Version)
url, err := JSONSchemaURL(strings.TrimSuffix(v.spec.Version, "-dev"))
if err != nil {
errs = multierror.Append(errs, err)
return errs
Expand Down
2 changes: 1 addition & 1 deletion validate/validate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func TestJSONSchema(t *testing.T) {
}{
{
config: &rspec.Spec{},
error: "1 error occurred:\n\t* Version string empty\nRefer to: https://github.com/opencontainers/runtime-spec/blob/v1.0.2/config.md#specification-version\n\n",
error: fmt.Sprintf("1 error occurred:\n\t* Version string empty\nRefer to: https://github.com/opencontainers/runtime-spec/blob/v%s/config.md#specification-version\n\n", rspec.Version),
},
{
config: &rspec.Spec{
Expand Down
10 changes: 5 additions & 5 deletions validation/util/test.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@ const (
LifecycleStatusStopped
)

var lifecycleStatusMap = map[string]LifecycleStatus{
"creating": LifecycleStatusCreating,
"created": LifecycleStatusCreated,
"running": LifecycleStatusRunning,
"stopped": LifecycleStatusStopped,
var lifecycleStatusMap = map[rspec.ContainerState]LifecycleStatus{
rspec.StateCreating: LifecycleStatusCreating,
rspec.StateCreated: LifecycleStatusCreated,
rspec.StateRunning: LifecycleStatusRunning,
rspec.StateStopped: LifecycleStatusStopped,
}

// LifecycleConfig includes
Expand Down
33 changes: 20 additions & 13 deletions vendor/github.com/opencontainers/runtime-spec/specs-go/config.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.