Skip to content

Commit 1259df0

Browse files
authored
kruise-game v1.0.0-rc release (#151)
Signed-off-by: ChrisLiu <[email protected]>
1 parent 2b75a2f commit 1259df0

21 files changed

+3836
-1
lines changed

charts/kruise-game

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
../versions/kruise-game/0.10
1+
../versions/kruise-game/1.0.0-rc
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Patterns to ignore when building packages.
2+
# This supports shell glob matching, relative path matching, and
3+
# negation (prefixed with !). Only one pattern per line.
4+
.DS_Store
5+
# Common VCS dirs
6+
.git/
7+
.gitignore
8+
.bzr/
9+
.bzrignore
10+
.hg/
11+
.hgignore
12+
.svn/
13+
# Common backup files
14+
*.swp
15+
*.bak
16+
*.tmp
17+
*.orig
18+
*~
19+
# Various IDEs
20+
.project
21+
.idea/
22+
*.tmproj
23+
.vscode/
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
apiVersion: v1
2+
name: kruise-game
3+
description: Helm chart for kruise-game components
4+
version: 1.0.0-rc
5+
appVersion: 1.0.0-rc
6+
kubeVersion: ">= 1.18.0-0"
7+
sources:
8+
- https://github.com/openkruise/kruise-game
9+
annotations:
10+
artifacthub.io/changes: |
11+
- "[Changed]: https://github.com/openkruise/kruise-game/blob/master/CHANGELOG.md"
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# Kruise Game v1.0.0
2+
3+
## Configuration
4+
5+
The following table lists the configurable parameters of the kruise-game chart and their default values.
6+
7+
| Parameter | Description | Default |
8+
|--------------------------------------------|-----------------------------------------------------------------------------|----------------------------------|
9+
| `installation.namespace` | Namespace for kruise-game operation installation | `kruise-game-system` |
10+
| `installation.createNamespace` | Whether to create the installation.namespace | `true` |
11+
| `kruiseGame.fullname` | Nick name for kruise-game deployment and other configurations | `kruise-game-controller-manager` |
12+
| `kruiseGame.healthBindPort` | Port for checking health of kruise-game container | `8082` |
13+
| `kruiseGame.webhook.port` | Port of webhook served by kruise-game container | `443` |
14+
| `kruiseGame.webhook.targetPort` | ObjectSelector for workloads in MutatingWebhookConfigurations | `9876` |
15+
| `kruiseGame.apiServerQps` | Indicates the maximum QPS to the master from kruise-game-controller-manager | `5` |
16+
| `kruiseGame.apiServerQpsBurst` | Maximum burst for throttle of kruise-game-controller-manager | `10` |
17+
| `kruiseGame.gameserverWorkers` | Max concurrent workers for GameServer controller | `10` |
18+
| `kruiseGame.gameserversetWorkers` | Max concurrent workers for GameServerSet controller | `10` |
19+
| `replicaCount` | Replicas of kruise-game deployment | `1` |
20+
| `image.repository` | Repository for kruise-game image | `openkruise/kruise-game-manager` |
21+
| `image.tag` | Tag for kruise-game image | `v1.0.0` |
22+
| `image.pullPolicy` | ImagePullPolicy for kruise-game container | `Always` |
23+
| `serviceAccount.annotations` | The annotations for serviceAccount of kruise-game | ` ` |
24+
| `service.port` | Port of kruise-game service | `8443` |
25+
| `resources.limits.cpu` | CPU resource limit of kruise-game container | `500m` |
26+
| `resources.limits.memory` | Memory resource limit of kruise-game container | `1Gi` |
27+
| `resources.requests.cpu` | CPU resource request of kruise-game container | `10m` |
28+
| `resources.requests.memory` | Memory resource request of kruise-game container | `64Mi` |
29+
| `prometheus.enabled` | Whether to bind metric endpoint | `true` |
30+
| `prometheus.monitorService.port` | Port of the monitorservice bind to | `8080` |
31+
| `scale.service.port` | Port of the external scaler server binds to | `6000` |
32+
| `scale.service.targetPort` | TargetPort of the external scaler server binds to | `6000` |
33+
| `network.totalWaitTime` | Maximum time to wait for network ready, the unit is seconds | `60` |
34+
| `network.probeIntervalTime` | Time interval for detecting network status, the unit is seconds | `5` |
35+
| `cloudProvider.installCRD` | Whether to install CloudProvider CRD | `true` |
36+
| `indexOffsetScheduler.enabled` | Whether to install index-offset-scheduler | `false` |
37+
| `certificates.autoGenerated` | Whether to auto-generate webhook certificates | `true` |
38+
| `certificates.secretName` | Name of the secret containing webhook certificates | `kruise-game-certs` |
39+
| `certificates.mountPath` | Path to mount webhook certificates in container | `/tmp/webhook-certs/` |
40+
| `certificates.certManager.enabled` | Whether to use cert-manager for certificate management | `false` |
41+
| `certificates.certManager.duration` | Certificate validity duration | `8760h0m0s` |
42+
| `certificates.certManager.renewBefore` | Time before expiry to renew certificate | `5840h0m0s` |
43+
| `certificates.certManager.generateCA` | Whether to generate a Certificate Authority | `true` |
44+
| `certificates.certManager.caSecretName` | Name of the secret containing the CA certificate | `kruise-game-ca` |
45+
| `certificates.certManager.issuer.generate` | Whether to generate the issuer automatically | `true` |
46+
| `certificates.certManager.issuer.name` | Name of the certificate issuer | `kruise-ca` |
47+
| `certificates.certManager.issuer.kind` | Type of the certificate issuer | `ClusterIssuer` |
48+
| `certificates.certManager.issuer.group` | API group of the certificate issuer | `cert-manager.io` |
49+
50+
51+
52+
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
53+
54+
### Optional: the local image for China
55+
56+
If you are in China and have problem to pull image from official DockerHub, you can use the registry hosted on Alibaba Cloud:
57+
58+
```bash
59+
$ helm install kruise-game https://... --set image.repository=registry.cn-hangzhou.aliyuncs.com/acs/kruise-game-manager
60+
...
61+
```
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
{{/*
2+
Expand the name of the chart.
3+
*/}}
4+
{{- define "kruise-game.name" -}}
5+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
6+
{{- end }}
7+
8+
{{/*
9+
Create a default fully qualified app name.
10+
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
11+
If release name contains chart name it will be used as a full name.
12+
*/}}
13+
{{- define "kruise-game.fullname" -}}
14+
{{- if .Values.fullnameOverride }}
15+
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
16+
{{- else }}
17+
{{- $name := default .Chart.Name .Values.nameOverride }}
18+
{{- if contains $name .Release.Name }}
19+
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
20+
{{- else }}
21+
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
22+
{{- end }}
23+
{{- end }}
24+
{{- end }}
25+
26+
{{/*
27+
Create chart name and version as used by the chart label.
28+
*/}}
29+
{{- define "kruise-game.chart" -}}
30+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
31+
{{- end }}
32+
33+
{{/*
34+
Common labels
35+
*/}}
36+
{{- define "kruise-game.labels" -}}
37+
helm.sh/chart: {{ include "kruise-game.chart" . }}
38+
{{ include "kruise-game.selectorLabels" . }}
39+
{{- if .Chart.AppVersion }}
40+
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
41+
{{- end }}
42+
app.kubernetes.io/managed-by: {{ .Release.Service }}
43+
{{- end }}
44+
45+
{{/*
46+
Selector labels
47+
*/}}
48+
{{- define "kruise-game.selectorLabels" -}}
49+
app.kubernetes.io/name: {{ include "kruise-game.name" . }}
50+
app.kubernetes.io/instance: {{ .Release.Name }}
51+
{{- end }}
52+
53+
{{/*
54+
Create the name of the service account to use
55+
*/}}
56+
{{- define "kruise-game.serviceAccountName" -}}
57+
{{- if .Values.serviceAccount.create }}
58+
{{- default (include "kruise-game.fullname" .) .Values.serviceAccount.name }}
59+
{{- else }}
60+
{{- default "default" .Values.serviceAccount.name }}
61+
{{- end }}
62+
{{- end }}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{{- if and .Values.certificates.certManager.enabled .Values.certificates.certManager.issuer.generate }}
2+
apiVersion: cert-manager.io/v1
3+
kind: Issuer
4+
metadata:
5+
name: {{ .Values.kruiseGame.fullname }}-issuer
6+
namespace: {{ .Values.installation.namespace }}
7+
spec:
8+
ca:
9+
secretName: {{ .Values.certificates.certManager.caSecretName }}
10+
{{- end }}
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{{- if .Values.certificates.certManager.enabled }}
2+
apiVersion: cert-manager.io/v1
3+
kind: Certificate
4+
metadata:
5+
name: {{ .Values.kruiseGame.fullname }}-cert
6+
namespace: {{ .Values.installation.namespace }}
7+
spec:
8+
commonName: {{ .Values.kruiseGame.fullname }}
9+
dnsNames:
10+
- {{ .Values.kruiseGame.webhook.serviceName }}.{{ .Values.installation.namespace }}
11+
- {{ .Values.kruiseGame.webhook.serviceName }}.{{ .Values.installation.namespace }}.svc
12+
- {{ .Values.kruiseGame.webhook.serviceName }}.{{ .Values.installation.namespace }}.svc.{{ .Values.clusterDomain }}
13+
secretName: {{ .Values.certificates.secretName }}
14+
usages:
15+
- server auth
16+
- client auth
17+
privateKey:
18+
rotationPolicy: Always
19+
algorithm: RSA
20+
size: 2048
21+
duration: {{ .Values.certificates.certManager.duration }}
22+
renewBefore: {{ .Values.certificates.certManager.renewBefore }}
23+
issuerRef:
24+
{{- if .Values.certificates.certManager.issuer.generate }}
25+
name: {{ .Values.kruiseGame.fullname }}-issuer
26+
kind: Issuer
27+
group: cert-manager.io
28+
{{- else }}
29+
{{- if .Values.certificates.certManager.issuer.name }}
30+
name: {{ .Values.certificates.certManager.issuer.name }}
31+
{{- end }}
32+
{{- if .Values.certificates.certManager.issuer.kind }}
33+
kind: {{ .Values.certificates.certManager.issuer.kind }}
34+
{{- end }}
35+
{{- if .Values.certificates.certManager.issuer.group }}
36+
group: {{ .Values.certificates.certManager.issuer.group }}
37+
{{- end }}
38+
{{- end }}
39+
{{- end }}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{{- if and .Values.certificates.certManager.enabled .Values.certificates.certManager.generateCA .Values.certificates.certManager.issuer.generate }}
2+
apiVersion: cert-manager.io/v1
3+
kind: Certificate
4+
metadata:
5+
name: {{ .Values.kruiseGame.fullname }}-ca
6+
namespace: {{ .Values.installation.namespace }}
7+
spec:
8+
isCA: true
9+
commonName: {{ .Values.kruiseGame.fullname }}
10+
secretName: {{ .Values.certificates.certManager.caSecretName }}
11+
privateKey:
12+
rotationPolicy: Always
13+
algorithm: RSA
14+
size: 2048
15+
duration: 8760h0m0s # 1 year
16+
renewBefore: 720h0m0s # 1 month
17+
issuerRef:
18+
name: {{ .Values.kruiseGame.fullname }}-selfsigned-issuer
19+
kind: Issuer
20+
group: cert-manager.io
21+
{{- end }}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{{- if and .Values.certificates.certManager.enabled .Values.certificates.certManager.generateCA .Values.certificates.certManager.issuer.generate }}
2+
apiVersion: cert-manager.io/v1
3+
kind: Issuer
4+
metadata:
5+
{{- with .Values.additionalAnnotations }}
6+
annotations:
7+
{{- toYaml . | nindent 4 }}
8+
{{- end }}
9+
name: {{ .Values.kruiseGame.fullname }}-selfsigned-issuer
10+
namespace: {{ .Values.installation.namespace }}
11+
spec:
12+
selfSigned: {}
13+
{{- end }}
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: kruise-game-manager-config
5+
namespace: {{ .Values.installation.namespace }}
6+
data:
7+
config.toml: |
8+
[kubernetes]
9+
enable = true
10+
[kubernetes.hostPort]
11+
max_port = 9000
12+
min_port = 8000
13+
14+
[alibabacloud]
15+
enable = true
16+
[alibabacloud.slb]
17+
max_port = 700
18+
min_port = 500
19+
block_ports = [593]
20+
[alibabacloud.nlb]
21+
max_port = 1502
22+
min_port = 1000
23+
block_ports = [1025, 1434, 1068]
24+
25+
[volcengine]
26+
enable = true
27+
[volcengine.clb]
28+
max_port = 600
29+
min_port = 550
30+
block_ports = [593]
31+
32+
[aws]
33+
enable = false
34+
[aws.nlb]
35+
max_port = 30050
36+
min_port = 30001
37+
38+
[jdcloud]
39+
enable = false
40+
[jdcloud.nlb]
41+
max_port = 700
42+
min_port = 500
43+
44+
[tencentcloud]
45+
enable = true
46+
47+
[hwcloud]
48+
enable = false
49+
[hwcloud.elb]
50+
max_port = 700
51+
min_port = 500
52+
block_ports = []
53+
54+
controller_manager_config.yaml: |
55+
apiVersion: controller-runtime.sigs.k8s.io/v1alpha1
56+
kind: ControllerManagerConfig
57+
health:
58+
healthProbeBindAddress: :8081
59+
metrics:
60+
bindAddress: 127.0.0.1:8080
61+
webhook:
62+
port: 9443
63+
leaderElection:
64+
leaderElect: true
65+
resourceName: c637bb1e.my.domain
66+
# leaderElectionReleaseOnCancel defines if the leader should step down volume
67+
# when the Manager ends. This requires the binary to immediately end when the
68+
# Manager is stopped, otherwise, this setting is unsafe. Setting this significantly
69+
# speeds up voluntary leader transitions as the new leader don't have to wait
70+
# LeaseDuration time first.
71+
# In the default scaffold provided, the program ends immediately after
72+
# the manager stops, so would be fine to enable this option. However,
73+
# if you are doing or is intended to do any operation such as perform cleanups
74+
# after the manager stops then its usage might be unsafe.
75+
# leaderElectionReleaseOnCancel: true
76+
77+

0 commit comments

Comments
 (0)