Skip to content

Commit

Permalink
Correctly mark optional fields
Browse files Browse the repository at this point in the history
Signed-off-by: Tamal Saha <[email protected]>
  • Loading branch information
tamalsaha committed May 26, 2020
1 parent 480ad5b commit 7775e7c
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 22 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
- name: Available platforms
run: echo ${{ steps.buildx.outputs.platforms }}

- name: Run checks
- name: Prepare Host
run: |
sudo apt-get -qq update || true
sudo apt-get install -y bzr
Expand All @@ -44,7 +44,9 @@ jobs:
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.17.0/bin/linux/amd64/kubectl
chmod +x ./kubectl
sudo mv ./kubectl /usr/local/bin/kubectl
# run checks
- name: Run checks
run: |
make ci
- name: Build
Expand Down
4 changes: 2 additions & 2 deletions api/crds/bindata.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func (fi bindataFileInfo) Sys() interface{} {
return nil
}

var _installerStashAppscodeCom_stashmongodbsYaml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xc4\x56\x5f\x6f\xe4\x34\x10\x7f\xdf\x4f\x31\x12\x48\x07\x88\x64\x29\x27\x21\xc8\x0b\x82\x1e\x48\x27\xee\x00\x5d\x8f\x7b\xa9\x0e\x69\xd6\x9e\x64\x4d\x1d\xdb\xcc\x4c\x96\xb6\x9f\x1e\xd9\x49\xb6\xfb\xb7\x50\x04\xc2\x4f\xeb\xdf\xfc\xff\xcd\x8c\x37\x98\xdc\x3b\x62\x71\x31\x34\x80\xc9\xd1\xad\x52\xc8\x37\xa9\x6f\xbe\x94\xda\xc5\xe5\xe6\x62\x45\x8a\x17\x8b\x1b\x17\x6c\x03\x97\x83\x68\xec\xdf\x90\xc4\x81\x0d\xbd\xa0\xd6\x05\xa7\x2e\x86\x45\x4f\x8a\x16\x15\x9b\x05\x80\x61\xc2\x0c\xbe\x75\x3d\x89\x62\x9f\x1a\x08\x83\xf7\x0b\x00\x8f\x2b\xf2\x92\x75\x00\x30\xa5\x06\x44\x51\xd6\x0b\x80\x80\x3d\x4d\xb7\x3e\x86\x2e\xda\x95\xd4\x2e\x88\xa2\xf7\xc4\x75\xc1\x6b\x4c\x49\x4c\xb4\x54\x9b\xd8\x2f\x24\x91\xc9\x7e\x3a\x8e\x43\x6a\xe0\x51\xdd\xd1\xfd\x14\xd6\xa0\x52\x17\xd9\xcd\xf7\x6a\x9b\x43\xfe\x3d\xdb\x95\xeb\x58\xf2\x55\x16\xbf\xce\x49\xbd\xf8\xb6\xc0\xde\x89\xfe\x70\x24\x7a\xe5\x44\x8b\x38\xf9\x81\xd1\x1f\x14\x53\x24\xe2\x42\x37\x78\xe4\x7d\xd9\x02\x20\x31\x09\xf1\x86\x7e\x09\x37\x21\xfe\x11\xbe\x77\xe4\xad\x34\xd0\xa2\x97\x9c\x89\x98\x98\xa8\x81\x1f\x73\x11\x09\x0d\xd9\x05\xc0\x06\xbd\xb3\x85\xe5\xb1\x8c\x98\x28\x7c\xf3\xf3\xcb\x77\xcf\xaf\xcc\x9a\x7a\x1c\xc1\xec\x39\x26\x62\xdd\x56\x3b\x12\xbf\x6d\xf9\x16\x03\xb0\x24\x86\x5d\x2a\x1e\xe1\x59\x76\x35\xea\x80\xcd\x4d\x26\x01\x5d\x13\x6c\x46\x8c\x2c\x48\x09\x03\xb1\x05\x5d\x3b\x01\xa6\x52\x43\xd0\x92\xd2\x8e\x5b\xc8\x2a\x18\x20\xae\x7e\x23\xa3\x35\x5c\xe5\x3a\x59\x40\xd6\x71\xf0\x16\x4c\x0c\x1b\x62\x05\x26\x13\xbb\xe0\xee\xb7\x9e\x05\x34\x96\x90\x1e\x95\x26\x66\xe7\xe3\x82\x12\x07\xf4\x99\x84\x81\x3e\x05\x0c\x16\x7a\xbc\x03\xa6\x1c\x03\x86\xb0\xe3\xad\xa8\x48\x0d\xaf\x23\x13\xb8\xd0\xc6\x06\xd6\xaa\x49\x9a\xe5\xb2\x73\x3a\x0f\xb9\x89\x7d\x3f\x04\xa7\x77\x4b\x13\x83\xb2\x5b\x0d\x1a\x59\x96\x96\x36\xe4\x97\xe2\xba\x0a\xd9\xac\x9d\x92\xd1\x81\x69\x89\xc9\x55\x25\xf1\xa0\x65\x53\x7a\xfb\x01\x4f\x1b\x21\xcf\x76\x32\xd5\xbb\x54\x86\x9a\x5d\xe8\xb6\x70\x19\xaa\xb3\xbc\xe7\xb9\x02\x27\x80\x93\xd9\x98\xff\x03\xbd\x19\xca\xac\xbc\xf9\xee\xea\x2d\xcc\x41\x4b\x0b\xf6\x39\x2f\x6c\x3f\x98\xc9\x03\xf1\x99\x28\x17\x5a\xe2\xb1\x71\x2d\xc7\xbe\x78\xa4\x60\x53\x74\x41\xcb\xc5\x78\x47\x61\x9f\x74\x19\x56\xbd\xd3\xdc\xe9\xdf\x07\x12\xcd\xfd\xa9\xe1\x12\x43\x88\x0a\x2b\x82\x21\x59\x54\xb2\x35\xbc\x0c\x70\x89\x3d\xf9\x4b\x14\xfa\xcf\x69\xcf\x0c\x4b\x95\x29\xfd\x6b\xe2\x77\x5f\xa8\xf9\x9c\x5a\x8f\x7c\xca\x73\xb4\x87\x00\xf4\x78\xfb\x8a\x42\xa7\xeb\x06\xbe\x78\x7e\x20\x4b\xa8\x79\x24\x1b\xf8\xf5\x1a\xab\xfb\xf7\x1f\x5d\x57\x58\xdd\x7f\x56\x7d\xf5\xfe\x93\xeb\xe9\xc7\xc7\x5f\x7f\x78\x60\x73\x32\xc9\x19\x1e\x1b\xb8\x85\xe7\xd7\xee\xe4\xd0\xec\xbe\x42\x57\x89\x4c\x9e\x9f\xdc\xc4\x69\x45\xdb\xc8\xa3\x0a\x4c\x3a\xd3\x4e\x40\xeb\x3c\xfd\x0d\x2e\x56\x68\x6e\x86\x74\xc8\xc6\x39\xed\x7c\x90\xbb\x13\xe8\xd9\x8a\xf3\xc9\x53\xe5\x98\xec\xa1\x59\x55\x9c\x9d\x64\xee\x80\xa2\x7c\xda\xc1\xfb\xdc\xba\x9f\x36\xc4\xec\xec\x51\x0b\xcf\x26\xe0\x7a\xec\x8e\xb4\x1f\x2b\x91\xa9\x73\xa2\x7c\xf7\xc4\x32\xb3\x61\x8a\xe2\x34\xfe\x03\x53\xc5\xee\x5f\x63\x75\xce\xff\x84\x60\xce\xef\x48\xa4\x78\xe8\xff\x6c\x23\x7a\xbc\xbd\x8c\xc1\x0c\xcc\x14\xcc\x51\xa5\x6d\xe4\x1e\x35\xff\x69\xeb\xf3\xcf\x4f\xba\xcc\x2f\x7c\x47\x7c\xb4\x93\x4f\x6e\x2c\x93\x68\xe4\x27\xb5\xf6\x7f\x9a\xde\x53\x3e\xaa\x69\xf9\xf6\xa0\x32\xab\x7b\xc8\x3e\xdb\x7b\xa2\xa9\xfe\xc7\xdf\x97\x03\x68\x33\x7f\x0f\x6e\x2e\xd0\xa7\x35\x5e\x3c\x60\x85\x98\x6a\xfa\x5a\xdb\x11\x03\x94\xef\x17\xdb\x80\xf2\x30\x46\xcb\x71\xf3\x52\x8d\xc8\x9f\x01\x00\x00\xff\xff\x62\x1e\xa7\x1e\x67\x0a\x00\x00")
var _installerStashAppscodeCom_stashmongodbsYaml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xb4\x56\x5f\x6f\x1c\x35\x10\x7f\xbf\x4f\x31\x12\x48\x05\xc4\xee\x11\x2a\x21\xd8\x17\x04\x29\x48\x15\x2d\xa0\xa6\xf4\x25\x2a\xd2\x9c\x3d\xbb\x67\xe2\xb5\xcd\xcc\xec\x91\xe4\xd3\x23\x7b\x77\x2f\xf7\x37\x34\x08\xfc\x74\xfe\xcd\xff\xdf\xcc\xf8\x16\x93\x7b\x47\x2c\x2e\x86\x06\x30\x39\xba\x55\x0a\xf9\x26\xf5\xcd\xd7\x52\xbb\xb8\xdc\x5c\xac\x48\xf1\x62\x71\xe3\x82\x6d\xe0\x72\x10\x8d\xfd\x1b\x92\x38\xb0\xa1\x17\xd4\xba\xe0\xd4\xc5\xb0\xe8\x49\xd1\xa2\x62\xb3\x00\x30\x4c\x98\xc1\xb7\xae\x27\x51\xec\x53\x03\x61\xf0\x7e\x01\xe0\x71\x45\x5e\xb2\x0e\x00\xa6\xd4\x80\x28\xca\x7a\x01\x10\xb0\xa7\xe9\xd6\xc7\xd0\x45\xbb\x92\xda\x05\x51\xf4\x9e\xb8\x2e\x78\x8d\x29\x89\x89\x96\x6a\x13\xfb\x85\x24\x32\xd9\x4f\xc7\x71\x48\x0d\x3c\xaa\x3b\xba\x9f\xc2\x1a\x54\xea\x22\xbb\xf9\x5e\x6d\x73\xc8\xbf\x67\xbb\x72\x1d\x4b\xbe\xca\xe2\xd7\x39\xa9\x17\xdf\x17\xd8\x3b\xd1\x9f\x8e\x44\xaf\x9c\x68\x11\x27\x3f\x30\xfa\x83\x62\x8a\x44\x5c\xe8\x06\x8f\xbc\x2f\x5b\x00\x24\x26\x21\xde\xd0\x6f\xe1\x26\xc4\xbf\xc2\x8f\x8e\xbc\x95\x06\x5a\xf4\x92\x33\x11\x13\x13\x35\xf0\x73\x2e\x22\xa1\x21\xbb\x00\xd8\xa0\x77\xb6\xb0\x3c\x96\x11\x13\x85\xef\x7e\x7d\xf9\xee\xf9\x95\x59\x53\x8f\x23\x98\x3d\xc7\x44\xac\xdb\x6a\x47\xe2\xb7\x2d\xdf\x62\x00\x96\xc4\xb0\x4b\xc5\x23\x3c\xcb\xae\x46\x1d\xb0\xb9\xc9\x24\xa0\x6b\x82\xcd\x88\x91\x05\x29\x61\x20\xb6\xa0\x6b\x27\xc0\x54\x6a\x08\x5a\x52\xda\x71\x0b\x59\x05\x03\xc4\xd5\x1f\x64\xb4\x86\xab\x5c\x27\x0b\xc8\x3a\x0e\xde\x82\x89\x61\x43\xac\xc0\x64\x62\x17\xdc\xfd\xd6\xb3\x80\xc6\x12\xd2\xa3\xd2\xc4\xec\x7c\x5c\x50\xe2\x80\x3e\x93\x30\xd0\xe7\x80\xc1\x42\x8f\x77\xc0\x94\x63\xc0\x10\x76\xbc\x15\x15\xa9\xe1\x75\x64\x02\x17\xda\xd8\xc0\x5a\x35\x49\xb3\x5c\x76\x4e\xe7\x21\x37\xb1\xef\x87\xe0\xf4\x6e\x69\x62\x50\x76\xab\x41\x23\xcb\xd2\xd2\x86\xfc\x52\x5c\x57\x21\x9b\xb5\x53\x32\x3a\x30\x2d\x31\xb9\xaa\x24\x1e\xb4\x6c\x4a\x6f\x3f\xe2\x69\x23\xe4\xd9\x4e\xa6\x7a\x97\xca\x50\xb3\x0b\xdd\x16\x2e\x43\x75\x96\xf7\x3c\x57\xe0\x04\x70\x32\x1b\xf3\x7f\xa0\x37\x43\x99\x95\x37\x3f\x5c\xbd\x85\x39\x68\x69\xc1\x3e\xe7\x85\xed\x07\x33\x79\x20\x3e\x13\xe5\x42\x4b\x3c\x36\xae\xe5\xd8\x17\x8f\x14\x6c\x8a\x2e\x68\xb9\x18\xef\x28\xec\x93\x2e\xc3\xaa\x77\x9a\x3b\xfd\xe7\x40\xa2\xb9\x3f\x35\x5c\x62\x08\x51\x61\x45\x30\x24\x8b\x4a\xb6\x86\x97\x01\x2e\xb1\x27\x7f\x89\x42\xff\x3b\xed\x99\x61\xa9\x32\xa5\xff\x4c\xfc\xee\x0b\x35\x9f\x53\xeb\x91\x4f\x79\x8e\xf6\x10\x80\x1e\x6f\x5f\x51\xe8\x74\xdd\xc0\x57\xcf\x0f\x64\x09\x35\x8f\x64\x03\xbf\x5f\x63\x75\xff\xfe\x93\xeb\x0a\xab\xfb\x2f\xaa\x6f\xde\x7f\x76\x3d\xfd\xf8\xf4\xdb\x8f\x0f\x6c\x4e\x26\x39\xc3\x63\x03\xb7\xf0\xfc\xda\x9d\x1c\x9a\xdd\x57\xe8\x2a\x91\xc9\xf3\x93\x9b\x38\xad\x68\x1b\x79\x54\x81\x49\x67\xda\x09\x68\x9d\xa7\x0f\xe0\x62\x85\xe6\x66\x48\x87\x6c\x9c\xd3\xce\x07\xb9\x3b\x81\x9e\xad\xf8\x6c\xd5\xf9\xb4\x83\xf7\xb9\x1b\xbf\x6c\x88\xd9\xd9\xa3\xae\x9c\xf5\xe9\x7a\xec\x8e\xb4\x1f\xcb\x9a\xa9\x73\xa2\x7c\xf7\xc4\xcc\xb3\x61\x8a\xe2\x34\xfe\x0b\x53\xc5\xee\x89\x36\x79\xfd\x1c\x93\x3d\x34\xab\xb6\xf9\x9f\x10\xcc\xf9\x1d\x89\x14\x3f\xb8\x11\x3d\xde\x5e\xc6\x60\x06\x66\x0a\xe6\xa8\xd2\x36\x72\x8f\x9a\xff\x87\xf5\xf9\x97\x27\x5d\xe6\x47\xbb\x23\x3e\x5a\xb3\x27\x37\x96\x49\x34\xf2\x93\x5a\xfb\xdf\x0d\xe4\x29\xfa\xab\x69\x45\xf6\xa0\x32\x7e\x7b\xc8\x3e\x81\x7b\xa2\xa9\xa4\xc7\x5f\x81\x03\x68\x33\x7f\xb5\x6d\x2e\xd0\xa7\x35\x5e\x3c\x60\xa5\xd6\x6a\xfa\xa6\xda\x11\x03\x94\xaf\x0c\xdb\x80\xf2\x30\x46\xcb\x71\xf3\x9e\x8c\xc8\xdf\x01\x00\x00\xff\xff\x1f\x70\x3b\x99\x0d\x0a\x00\x00")

func installerStashAppscodeCom_stashmongodbsYamlBytes() ([]byte, error) {
return bindataRead(
Expand All @@ -92,7 +92,7 @@ func installerStashAppscodeCom_stashmongodbsYaml() (*asset, error) {
return nil, err
}

info := bindataFileInfo{name: "installer.stash.appscode.com_stashmongodbs.yaml", size: 2663, mode: os.FileMode(420), modTime: time.Unix(1573722179, 0)}
info := bindataFileInfo{name: "installer.stash.appscode.com_stashmongodbs.yaml", size: 2573, mode: os.FileMode(420), modTime: time.Unix(1573722179, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}
Expand Down
4 changes: 0 additions & 4 deletions api/crds/installer.stash.appscode.com_stashmongodbs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@ spec:
properties:
args:
type: string
required:
- args
type: object
fullnameOverride:
type: string
Expand All @@ -71,8 +69,6 @@ spec:
properties:
args:
type: string
required:
- args
type: object
required:
- backup
Expand Down
6 changes: 0 additions & 6 deletions api/openapi-spec/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -887,9 +887,6 @@
},
"dev.appscode.stash.mongodb.apis.installer.v1alpha1.MongoDBBackup": {
"type": "object",
"required": [
"args"
],
"properties": {
"args": {
"type": "string"
Expand All @@ -898,9 +895,6 @@
},
"dev.appscode.stash.mongodb.apis.installer.v1alpha1.MongoDBRestore": {
"type": "object",
"required": [
"args"
],
"properties": {
"args": {
"type": "string"
Expand Down
2 changes: 2 additions & 0 deletions apis/installer/v1alpha1/generated.proto

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

2 changes: 0 additions & 2 deletions apis/installer/v1alpha1/openapi_generated.go

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

6 changes: 4 additions & 2 deletions apis/installer/v1alpha1/stash_mongodb_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ type StashMongoDB struct {

// StashMongoDBSpec is the schema for Stash MongoDB values file
type StashMongoDBSpec struct {
//+optional
// +optional
NameOverride string `json:"nameOverride" protobuf:"bytes,1,opt,name=nameOverride"`
//+optional
// +optional
FullnameOverride string `json:"fullnameOverride" protobuf:"bytes,2,opt,name=fullnameOverride"`
Image ImageRef `json:"image" protobuf:"bytes,3,opt,name=image"`
Backup MongoDBBackup `json:"backup" protobuf:"bytes,4,opt,name=backup"`
Expand All @@ -60,10 +60,12 @@ type ImageRef struct {
}

type MongoDBBackup struct {
// +optional
Args string `json:"args" protobuf:"bytes,1,opt,name=args"`
}

type MongoDBRestore struct {
// +optional
Args string `json:"args" protobuf:"bytes,1,opt,name=args"`
}

Expand Down
4 changes: 0 additions & 4 deletions charts/stash-mongodb/values.openapiv3_schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ properties:
properties:
args:
type: string
required:
- args
type: object
fullnameOverride:
type: string
Expand All @@ -30,8 +28,6 @@ properties:
properties:
args:
type: string
required:
- args
type: object
required:
- backup
Expand Down

0 comments on commit 7775e7c

Please sign in to comment.