Skip to content

Commit

Permalink
Use ace.appscode.com/managed label
Browse files Browse the repository at this point in the history
Signed-off-by: Tamal Saha <[email protected]>
  • Loading branch information
tamalsaha committed Oct 27, 2023
1 parent 42c843a commit 9a37117
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 15 deletions.
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ require (
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.8.3
github.com/zeebo/xxh3 v1.0.2
go.bytebuilders.dev/license-verifier v0.13.3
go.bytebuilders.dev/license-verifier v0.13.4
go.openviz.dev/apimachinery v0.0.4
golang.org/x/sync v0.4.0
gomodules.xyz/jsonpath v0.0.2
Expand All @@ -46,7 +46,7 @@ require (
kmodules.xyz/custom-resources v0.25.2
kmodules.xyz/go-containerregistry v0.0.11
kmodules.xyz/monitoring-agent-api v0.25.4
kmodules.xyz/resource-metadata v0.17.28
kmodules.xyz/resource-metadata v0.17.29
kmodules.xyz/resource-metrics v0.25.7
kmodules.xyz/sets v0.25.0
kubeops.dev/scanner v0.0.15
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1288,8 +1288,8 @@ github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f/go
github.com/zeebo/assert v1.3.0 h1:g7C04CbJuIDKNPFHmsk4hwZDO5O+kntRxzaUoNXj+IQ=
github.com/zeebo/xxh3 v1.0.2 h1:xZmwmqxHZA8AI603jOQ0tMqmBr9lPeFwGg6d+xy9DC0=
github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA=
go.bytebuilders.dev/license-verifier v0.13.3 h1:/CnRn1N6qiFjdirydHVBDtOtSlCwOm8cgUi0plZNgjU=
go.bytebuilders.dev/license-verifier v0.13.3/go.mod h1:PTTlWgokzoisBezn2zt+JeGkhTJZ0flvLzdhHVBy86M=
go.bytebuilders.dev/license-verifier v0.13.4 h1:K4qSsTWTZc7lyRvRHfI23XRrbVrQVJ8Ew5afvSiMdBE=
go.bytebuilders.dev/license-verifier v0.13.4/go.mod h1:lcmFhUSBHp5G0YeZop3I8tOUBRegBrDvkW1aTsIRGcU=
go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
Expand Down Expand Up @@ -2151,8 +2151,8 @@ kmodules.xyz/monitoring-agent-api v0.25.4 h1:OwkvtV23QhUy3f7o9lxPWaAW3jiJMGAMPPR
kmodules.xyz/monitoring-agent-api v0.25.4/go.mod h1:3LhrLDGQKQXhxYcjA/WNaO4HPpopYQzOutsEp2i3008=
kmodules.xyz/offshoot-api v0.25.4 h1:IjJNvkphcdYUG8XO/pBwXpuP8W+jxAWJZ3yH8vgI/as=
kmodules.xyz/offshoot-api v0.25.4/go.mod h1:PUk4EuJFhhyQykCflHj7EgXcljGIqs9vi0IN0RpxtY4=
kmodules.xyz/resource-metadata v0.17.28 h1:zNCRy8TxuXemsKRiRqOVaCPwRJpAsvNG2KhlMq+cJdU=
kmodules.xyz/resource-metadata v0.17.28/go.mod h1:qA/yeimciDU7szGPyRT3jHDPIvm7uJiVOzcB5tIJgxE=
kmodules.xyz/resource-metadata v0.17.29 h1:bB1omnXVkN5fWOpV/0a9wEjX0JdqaS5vCYUP0LHCzKI=
kmodules.xyz/resource-metadata v0.17.29/go.mod h1:qA/yeimciDU7szGPyRT3jHDPIvm7uJiVOzcB5tIJgxE=
kmodules.xyz/resource-metrics v0.25.7 h1:ne2cK/dlnfYcuu0+pHX15Y53rcKBQq9DuCtQVcx6rY8=
kmodules.xyz/resource-metrics v0.25.7/go.mod h1:y7pDmTWuVLNGSjwckKCwJFhCgi5fhbwS7PAcH2rmGcY=
kmodules.xyz/sets v0.25.0 h1:belY/3trp/M/CKc1TEteA40jb2uCIdwKHhjpvrIxG+8=
Expand Down
7 changes: 2 additions & 5 deletions pkg/registry/meta/clusterstatus/fluxcd.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,10 @@ import (
apierrors "k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/meta"
"k8s.io/apimachinery/pkg/runtime/schema"
rsapi "kmodules.xyz/resource-metadata/apis/meta/v1alpha1"
"sigs.k8s.io/controller-runtime/pkg/client"
)

const (
KeyACEManaged = "byte.builders/managed"
)

type FluxCDStatus struct {
Installed bool `json:"installed"`
Ready bool `json:"ready"`
Expand Down Expand Up @@ -86,7 +83,7 @@ func getFluxCDStatus(kc client.Client) (FluxCDStatus, error) {
}

func isFluxCDManaged(podLabels map[string]string) bool {
_, exists := podLabels[KeyACEManaged]
_, exists := podLabels[rsapi.KeyACEManaged]
return exists
}

Expand Down
7 changes: 5 additions & 2 deletions vendor/go.bytebuilders.dev/license-verifier/info/lib.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,9 @@ var (
ProductName string // This has been renamed to Features
ProductUID string

ProdDomain = "byte.builders"
QADomain = "appscode.ninja"
QADomain = "appscode.ninja"
ProdDomain = "appscode.com"
DeprecatedProdDomain = "byte.builders"

registrationAPIPath = "api/v1/register"
LicenseIssuerAPIPath = "api/v1/license/issue"
Expand Down Expand Up @@ -143,8 +144,10 @@ func HostedEndpoint(u string) (bool, error) {

func HostedDomain(d string) bool {
return d == ProdDomain ||
d == DeprecatedProdDomain ||
d == QADomain ||
strings.HasSuffix(d, "."+ProdDomain) ||
strings.HasSuffix(d, "."+DeprecatedProdDomain) ||
strings.HasSuffix(d, "."+QADomain)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ const (
ResourceClusterStatuses = "clusterstatuses"
)

const (
KeyACEManaged = "ace.appscode.com/managed"
)

// ClusterStatus is the Schema for any resource supported by resource-metrics library

// +genclient
Expand Down
4 changes: 2 additions & 2 deletions vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -718,7 +718,7 @@ github.com/yudai/golcs
# github.com/zeebo/xxh3 v1.0.2
## explicit; go 1.17
github.com/zeebo/xxh3
# go.bytebuilders.dev/license-verifier v0.13.3
# go.bytebuilders.dev/license-verifier v0.13.4
## explicit; go 1.18
go.bytebuilders.dev/license-verifier/apis/licenses
go.bytebuilders.dev/license-verifier/info
Expand Down Expand Up @@ -1839,7 +1839,7 @@ kmodules.xyz/monitoring-agent-api/client
# kmodules.xyz/offshoot-api v0.25.4
## explicit; go 1.18
kmodules.xyz/offshoot-api/api/v1
# kmodules.xyz/resource-metadata v0.17.28
# kmodules.xyz/resource-metadata v0.17.29
## explicit; go 1.18
kmodules.xyz/resource-metadata/apis/core/install
kmodules.xyz/resource-metadata/apis/core/v1alpha1
Expand Down

0 comments on commit 9a37117

Please sign in to comment.