Skip to content

Commit b660b32

Browse files
authored
Merge branch 'kosmos-io:main' into fix_operator_join
2 parents 0a662ae + 37cb260 commit b660b32

File tree

448 files changed

+51625
-1624
lines changed

Some content is hidden

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

448 files changed

+51625
-1624
lines changed

.github/workflows/ci.yml

+3
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ concurrency:
99
jobs:
1010
verify:
1111
name: verify
12+
# runs-on: ubuntu-22.04
1213
runs-on: [self-hosted, ecs]
1314
if: ${{ always() }}
1415
env:
@@ -27,6 +28,8 @@ jobs:
2728
uses: actions/setup-go@v4
2829
with:
2930
go-version: '1.20'
31+
- name: Set up GOPROXY for Go
32+
run: go env -w GOPROXY=https://goproxy.cn,direct
3033
- name: lint
3134
run: hack/verify-staticcheck.sh
3235
- name: vendor

.github/workflows/release_binaries.yml

+7-4
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ jobs:
3030
- name: Install Go
3131
uses: actions/setup-go@v3
3232

33+
- name: Set up GOPROXY for Go
34+
run: go env -w GOPROXY=https://goproxy.cn,direct
35+
3336
# step3: make binaries
3437
- name: Make binaries
3538
run: make release
@@ -40,8 +43,8 @@ jobs:
4043
if: startsWith(github.ref, 'refs/tags/')
4144
with:
4245
files: |
43-
_output/release/kosmosctl-linux-amd64
44-
_output/release/kosmosctl-linux-arm64
45-
_output/release/kosmosctl-darwin-amd64
46-
_output/release/kosmosctl-darwin-arm64
46+
_output/release/kosmosctl/kosmosctl-linux-amd64
47+
_output/release/kosmosctl/kosmosctl-linux-arm64
48+
_output/release/kosmosctl/kosmosctl-darwin-amd64
49+
_output/release/kosmosctl/kosmosctl-darwin-arm64
4750

.gitignore

+9-1
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,12 @@ kube-config
3030

3131
__debug_bin*
3232

33-
ignore_dir
33+
ignore_dir
34+
cmd/kubenest/node-agent/app.log
35+
cmd/kubenest/node-agent/cert.pem
36+
cmd/kubenest/node-agent/key.pem
37+
cmd/kubenest/node-agent/agent.env
38+
hack/k8s-in-k8s/nodes.txt
39+
develop
40+
41+
cmd/kubenest/node-agent/app/client/app.log

.golangci.yml

+21-10
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,33 @@
11
run:
22
timeout: 10m
33
modules-download-mode: vendor
4+
skip-dirs:
5+
- (^|/)vendor($|/)
6+
- pkg/utils/lifted
7+
- pkg/scheduler/lifted
48
linters:
59
disable-all: true
610
enable:
7-
- whitespace
8-
- bodyclose
9-
- dupl
10-
- errcheck
11-
- gci
11+
# linters maintained by golang.org
1212
- gofmt
13+
- govet
1314
- goimports
14-
- misspell
15-
- unused
15+
# linters default enabled by golangci-lint .
16+
- errcheck
17+
- gosimple
1618
- typecheck
1719
- staticcheck
18-
- gosimple
19-
- govet
2020
- ineffassign
21-
- typecheck
21+
- unused
22+
# other linters supported by golangci-lint.
23+
- gci
24+
- misspell
25+
- bodyclose
26+
- gocyclo
2227
- gosec
28+
- dupl
29+
- revive
30+
- whitespace
2331
linters-settings:
2432
goimports:
2533
local-prefixes: github.com/kosmos.io/kosmos
@@ -31,6 +39,9 @@ linters-settings:
3139
- Standard
3240
- Default
3341
- Prefix(github.com/kosmos.io/kosmos)
42+
gocyclo:
43+
# minimal cyclomatic complexity to report
44+
min-complexity: 40 # The recommended value is 15
3445
output:
3546
sort-results: true
3647

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ lint-fix: golangci-lint
151151

152152
golangci-lint:
153153
ifeq (, $(shell which golangci-lint))
154-
GO111MODULE=on go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.54.2
154+
GO111MODULE=on go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.55.2
155155
GOLANGLINT_BIN=$(shell go env GOPATH)/bin/golangci-lint
156156
else
157157
GOLANGLINT_BIN=$(shell which golangci-lint)

charts/kosmos/Chart.yaml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
apiVersion: v2
2+
name: kosmos-charts
3+
description: A Helm chart for Kosmos
4+
5+
# A chart can be either an 'application' or a 'library' chart.
6+
#
7+
# Application charts are a collection of templates that can be packaged into versioned archives
8+
# to be deployed.
9+
#
10+
# Library charts provide useful utilities or functions for the chart developer. They're included as
11+
# a dependency of application charts to inject those utilities and functions into the rendering
12+
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
13+
type: application
14+
15+
# The optional kubeVersion field can define semver constraints on supported Kubernetes versions.
16+
# Helm will validate the version constraints when installing the chart and fail if the cluster
17+
# runs an unsupported Kubernetes version.
18+
kubeVersion: ">= 1.16.0-0"
19+
20+
# This is the chart version. This version number should be incremented each time you make changes
21+
# to the chart and its templates, including the app version.
22+
# Versions are expected to follow Semantic Versioning (https://semver.org/)
23+
version: 0.0.0
24+
25+
# This is the version number of the application being deployed. This version number should be
26+
# incremented each time you make changes to the application. Versions are not expected to
27+
# follow Semantic Versioning. They should reflect the version the application is using.
28+
# It is recommended to use it with quotes.
29+
appVersion: latest
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
apiVersion: v1
2+
kind: ServiceAccount
3+
metadata:
4+
name: clustertree
5+
namespace: {{ .Values.global.namespace }}
6+
---
7+
apiVersion: v1
8+
kind: ServiceAccount
9+
metadata:
10+
name: kosmos-operator
11+
namespace: {{ .Values.global.namespace }}
12+
---
13+
apiVersion: v1
14+
kind: ServiceAccount
15+
metadata:
16+
name: kosmos-scheduler
17+
namespace: {{ .Values.global.namespace }}
18+
---
19+
apiVersion: v1
20+
kind: ServiceAccount
21+
metadata:
22+
name: clusterlink-controller-manager
23+
namespace: {{ .Values.global.namespace }}
24+
---
25+
apiVersion: v1
26+
kind: ServiceAccount
27+
metadata:
28+
name: clusterlink-elector
29+
namespace: {{ .Values.global.namespace }}
30+
---
31+
apiVersion: v1
32+
kind: ServiceAccount
33+
metadata:
34+
name: clusterlink-network-manager
35+
namespace: {{ .Values.global.namespace }}

0 commit comments

Comments
 (0)