Skip to content

Commit af7bcce

Browse files
authored
Merge pull request #2202 from prestist/3.6-stable
Stabilize Ignition spec 3.6
2 parents 5a45ee8 + 8ab8a64 commit af7bcce

189 files changed

Lines changed: 5715 additions & 105 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

config/config.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
package config
1616

1717
import (
18-
exp "github.com/coreos/ignition/v2/config/v3_6_experimental"
19-
types_exp "github.com/coreos/ignition/v2/config/v3_6_experimental/types"
18+
exp "github.com/coreos/ignition/v2/config/v3_7_experimental"
19+
types_exp "github.com/coreos/ignition/v2/config/v3_7_experimental/types"
2020

2121
"github.com/coreos/vcontext/report"
2222
)

config/config_test.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ import (
2626
v3_3 "github.com/coreos/ignition/v2/config/v3_3/types"
2727
v3_4 "github.com/coreos/ignition/v2/config/v3_4/types"
2828
v3_5 "github.com/coreos/ignition/v2/config/v3_5/types"
29-
v3_6 "github.com/coreos/ignition/v2/config/v3_6_experimental/types"
29+
v3_6 "github.com/coreos/ignition/v2/config/v3_6/types"
30+
v3_7 "github.com/coreos/ignition/v2/config/v3_7_experimental/types"
3031
)
3132

3233
type typeSet map[reflect.Type]struct{}
@@ -276,6 +277,7 @@ func TestConfigStructure(t *testing.T) {
276277
reflect.TypeOf(v3_4.Config{}),
277278
reflect.TypeOf(v3_5.Config{}),
278279
reflect.TypeOf(v3_6.Config{}),
280+
reflect.TypeOf(v3_7.Config{}),
279281
}
280282

281283
for _, configType := range configs {

config/merge/merge_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import (
1919

2020
"github.com/coreos/ignition/v2/config/util"
2121
v3_2 "github.com/coreos/ignition/v2/config/v3_2/types"
22-
"github.com/coreos/ignition/v2/config/v3_6_experimental/types"
22+
"github.com/coreos/ignition/v2/config/v3_7_experimental/types"
2323

2424
"github.com/coreos/vcontext/path"
2525
"github.com/stretchr/testify/assert"
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,15 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15-
package v3_6_experimental
15+
package v3_6
1616

1717
import (
1818
"github.com/coreos/ignition/v2/config/merge"
1919
"github.com/coreos/ignition/v2/config/shared/errors"
2020
"github.com/coreos/ignition/v2/config/util"
2121
prev "github.com/coreos/ignition/v2/config/v3_5"
22-
"github.com/coreos/ignition/v2/config/v3_6_experimental/translate"
23-
"github.com/coreos/ignition/v2/config/v3_6_experimental/types"
22+
"github.com/coreos/ignition/v2/config/v3_6/translate"
23+
"github.com/coreos/ignition/v2/config/v3_6/types"
2424
"github.com/coreos/ignition/v2/config/validate"
2525

2626
"github.com/coreos/go-semver/semver"
@@ -58,8 +58,8 @@ func Parse(rawConfig []byte) (types.Config, report.Report, error) {
5858
return config, rpt, nil
5959
}
6060

61-
// ParseCompatibleVersion parses the raw config of version 3.5.0-experimental or
62-
// lesser into a 3.5-exp types.Config struct and generates a report of any errors,
61+
// ParseCompatibleVersion parses the raw config of version 3.6.0 or
62+
// lesser into a 3.6 types.Config struct and generates a report of any errors,
6363
// warnings, info, and deprecations it encountered
6464
func ParseCompatibleVersion(raw []byte) (types.Config, report.Report, error) {
6565
version, rpt, err := util.GetConfigVersion(raw)
Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15-
package v3_6_experimental
15+
package v3_6
1616

1717
import (
1818
"testing"
1919

2020
"github.com/coreos/ignition/v2/config/shared/errors"
21-
"github.com/coreos/ignition/v2/config/v3_6_experimental/types"
21+
"github.com/coreos/ignition/v2/config/v3_6/types"
2222
"github.com/stretchr/testify/assert"
2323
)
2424

@@ -137,6 +137,10 @@ func TestParse(t *testing.T) {
137137
},
138138
{
139139
in: in{config: []byte(`{"ignition": {"version": "3.6.0-experimental"}}`)},
140+
out: out{err: errors.ErrUnknownVersion},
141+
},
142+
{
143+
in: in{config: []byte(`{"ignition": {"version": "3.6.0"}}`)},
140144
out: out{config: types.Config{Ignition: types.Ignition{Version: types.MaxVersion.String()}}},
141145
},
142146
{
@@ -156,7 +160,7 @@ func TestParse(t *testing.T) {
156160
out: out{err: errors.ErrEmpty},
157161
},
158162
{
159-
in: in{config: []byte(`{"ignition": {"version": "3.6.0-experimental"}, "storage": {"filesystems": [{"format": "ext4", "label": "zzzzzzzzzzzzzzzzzzzzzzzzzzz"}]}}`)},
163+
in: in{config: []byte(`{"ignition": {"version": "3.6.0"}, "storage": {"filesystems": [{"format": "ext4", "label": "zzzzzzzzzzzzzzzzzzzzzzzzzzz"}]}}`)},
160164
out: out{err: errors.ErrInvalid},
161165
},
162166
}
@@ -191,11 +195,11 @@ func TestParse(t *testing.T) {
191195
},
192196
{
193197
in: in{config: []byte(`{"ignition": {"version": "3.6.0-experimental"}}`)},
194-
out: out{config: types.Config{Ignition: types.Ignition{Version: types.MaxVersion.String()}}},
198+
out: out{err: errors.ErrUnknownVersion},
195199
},
196200
{
197201
in: in{config: []byte(`{"ignition": {"version": "3.6.0"}}`)},
198-
out: out{err: errors.ErrUnknownVersion},
202+
out: out{config: types.Config{Ignition: types.Ignition{Version: types.MaxVersion.String()}}},
199203
},
200204
{
201205
in: in{config: []byte(`{"ignition": {"version": "3.7.0"}}`)},
@@ -210,7 +214,7 @@ func TestParse(t *testing.T) {
210214
out: out{err: errors.ErrInvalid},
211215
},
212216
{
213-
in: in{config: []byte(`{"ignition": {"version": "3.6.0-experimental"}, "storage": {"filesystems": [{"format": "ext4", "label": "zzzzzzzzzzzzzzzzzzzzzzzzzzz"}]}}`)},
217+
in: in{config: []byte(`{"ignition": {"version": "3.6.0"}, "storage": {"filesystems": [{"format": "ext4", "label": "zzzzzzzzzzzzzzzzzzzzzzzzzzz"}]}}`)},
214218
out: out{err: errors.ErrInvalid},
215219
},
216220
}
File renamed without changes.

config/v3_6_experimental/translate/translate.go renamed to config/v3_6/translate/translate.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import (
1818
"github.com/coreos/ignition/v2/config/translate"
1919
"github.com/coreos/ignition/v2/config/util"
2020
old_types "github.com/coreos/ignition/v2/config/v3_5/types"
21-
"github.com/coreos/ignition/v2/config/v3_6_experimental/types"
21+
"github.com/coreos/ignition/v2/config/v3_6/types"
2222
)
2323

2424
func translateFileEmbedded1(old old_types.FileEmbedded1) (ret types.FileEmbedded1) {
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)