Skip to content

Commit

Permalink
add revive linter and fix the lint error
Browse files Browse the repository at this point in the history
Signed-off-by: duanmengkk <[email protected]>
  • Loading branch information
duanmengkk committed Sep 14, 2024
1 parent 5375a44 commit 323fb31
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 147 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ concurrency:
jobs:
verify:
name: verify
runs-on: ubuntu-22.04
# runs-on: [self-hosted, ecs]
# runs-on: ubuntu-22.04
runs-on: [self-hosted, ecs]
if: ${{ always() }}
env:
#GOPATH: ${{ github.workspace }}
Expand Down
127 changes: 0 additions & 127 deletions deploy/crds/kosmos.io_knodes.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion deploy/crds/kosmos.io_kubenestconfigurations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ spec:
type: string
type: array
type: object
useTenantDns:
useTenantDNS:
default: false
type: boolean
type: object
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/kosmos.io_virtualclusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ spec:
type: string
type: array
type: object
useTenantDns:
useTenantDNS:
default: false
type: boolean
type: object
Expand Down
8 changes: 0 additions & 8 deletions examples/knode-demo.yaml

This file was deleted.

1 change: 1 addition & 0 deletions hack/rune2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ MEMBER3_CLUSTER_NAME="cluster-member3"

ROOT="$(dirname "${BASH_SOURCE[0]}")"
REPO_ROOT="$(dirname "${BASH_SOURCE[0]}")/.."
source "$(dirname "${BASH_SOURCE[0]}")/install_kind_kubectl.sh"
source "${ROOT}/util.sh"
source "${ROOT}/cluster.sh"
mkdir -p "$ARTIFACTS_PATH"
Expand Down
2 changes: 1 addition & 1 deletion pkg/generated/openapi/zz_generated.openapi.go

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

12 changes: 5 additions & 7 deletions pkg/kubenest/controlplane/etcd.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func DeleteVirtualClusterEtcd(client clientset.Interface, name, namespace string
return nil
}

// nolint:revive
// nolint
func installEtcd(client clientset.Interface, name, namespace string, kubeNestConfiguration *v1alpha1.KubeNestConfiguration, vc *v1alpha1.VirtualCluster) error {
imageRepository, imageVersion := util.GetImageMessage()

Expand All @@ -52,15 +52,13 @@ func installEtcd(client clientset.Interface, name, namespace string, kubeNestCon
namespace,
constants.EtcdListenPeerPort,
)

initialClusters[index] = fmt.Sprintf("%s=%s", memberName, memberPeerURL)
}
vclabel := util.GetVirtualControllerLabel()
IPV6FirstFlag, err := util.IPV6First(constants.APIServerServiceSubnet)
if err != nil {
vcLabel := util.GetVirtualControllerLabel()
IPV6FirstFlag, newErr := util.IPV6First(constants.APIServerServiceSubnet)
if newErr != nil {
return err
}

etcdStatefulSetBytes, err := util.ParseTemplate(etcd.EtcdStatefulSet, struct {
StatefulSetName, Namespace, ImageRepository, Image, EtcdClientService, Version, VirtualControllerLabel string
CertsSecretName, EtcdPeerServiceName string
Expand All @@ -73,7 +71,7 @@ func installEtcd(client clientset.Interface, name, namespace string, kubeNestCon
Namespace: namespace,
ImageRepository: imageRepository,
Version: imageVersion,
VirtualControllerLabel: vclabel,
VirtualControllerLabel: vcLabel,
EtcdClientService: util.GetEtcdClientServerName(name),
CertsSecretName: util.GetEtcdCertName(name),
EtcdPeerServiceName: util.GetEtcdServerName(name),
Expand Down

0 comments on commit 323fb31

Please sign in to comment.