debian-forge-composer/go.mod
Brian C. Lane 58839cf927 Use semver to enforce blueprint version numbers
This changes osbuild-composer's behavior to match lorax-composer when
encountering invalid versions. Instead of leaving them as-is it will
return a BlueprintError explaining the problem. eg.

"errors": [
    {
        "id": "BlueprintsError",
        "msg": "Invalid 'version', must use Semantic Versioning:  is not in dotted-tri format"
    }
]

This is enforced on new blueprints (including the workspace). If a
previously stored blueprint has an invalid version and a new one is
pushed it will use the new version number instead of trying to bump the
invalid one.

This also moves the version bump logic into blueprint instead of store,
and adds an Initialize function that will make sure that the blueprint
has sane default values for any missing fields.

This includes tests for the Initialize and BumpVersion functions.
2020-02-25 09:00:35 +01:00

20 lines
706 B
Modula-2

module github.com/osbuild/osbuild-composer
go 1.12
require (
github.com/Azure/azure-storage-blob-go v0.8.0
github.com/Azure/go-autorest/autorest/adal v0.8.2 // indirect
github.com/BurntSushi/toml v0.3.1
github.com/aws/aws-sdk-go v1.25.37
github.com/coreos/go-semver v0.3.0
github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f
github.com/gobwas/glob v0.2.3
github.com/google/go-cmp v0.3.1
github.com/google/uuid v1.1.1
github.com/julienschmidt/httprouter v1.2.0
github.com/pkg/errors v0.9.1 // indirect
github.com/stretchr/testify v1.4.0 // indirect
golang.org/x/net v0.0.0-20200202094626-16171245cfb2 // indirect
golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4 // indirect
)