Skip to content

Commit

Permalink
Bump k3d to v5.1.0
Browse files Browse the repository at this point in the history
- k3d config examples migrated to `apiVersion: k3d.io/v1alpha3`
  [https://github.com/rancher/k3d/pull/605](https://github.com/rancher/k3d/pull/605)
- `:direct` node filter option used when load balancer is disabled
  [https://github.com/rancher/k3d/pull/656](https://github.com/rancher/k3d/pull/656)
- `--label` --> `--runtime-label`
  [https://github.com/rancher/k3d/pull/598](https://github.com/rancher/k3d/pull/598)
- `--k3s-server-arg` --> `--k3s-arg` with server node filter (`@server:*`)
  [https://github.com/rancher/k3d/pull/605](https://github.com/rancher/k3d/pull/605)
- removed `disableImageVolume` option from examples and test assets
- Updated documentation

Signed-off-by: Timofey Ilinykh <[email protected]>
  • Loading branch information
somaritane committed Nov 15, 2021
1 parent c75fedf commit 8781d81
Show file tree
Hide file tree
Showing 17 changed files with 140 additions and 138 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/assets/1.yaml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
apiVersion: k3d.io/v1alpha2
apiVersion: k3d.io/v1alpha3
kind: Simple
image: docker.io/rancher/k3s:v1.21.2-k3s1
servers: 1
agents: 3
ports:
- port: 0.0.0.0:80:80
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:443:443
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:5053:53/udp
nodeFilters:
- agent[0]
- agent:0:direct
options:
k3d:
wait: true
timeout: "60s"
timeout: 1m0s
disableLoadbalancer: true
disableImageVolume: true
k3s:
extraServerArgs:
- --no-deploy=traefik,servicelb,metrics-server
extraAgentArgs: []
extraArgs:
- arg: --no-deploy=traefik,servicelb,metrics-server
nodeFilters:
- server:*
kubeconfig:
updateDefaultKubeconfig: true
switchCurrentContext: true
18 changes: 9 additions & 9 deletions .github/workflows/assets/2.yaml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
apiVersion: k3d.io/v1alpha2
apiVersion: k3d.io/v1alpha3
kind: Simple
image: docker.io/rancher/k3s:v1.21.2-k3s1
servers: 1
agents: 3
ports:
- port: 0.0.0.0:81:80
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:444:443
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:5054:53/udp
nodeFilters:
- agent[0]
- agent:0:direct
options:
k3d:
wait: true
timeout: "60s"
timeout: 1m0s
disableLoadbalancer: true
disableImageVolume: true
k3s:
extraServerArgs:
- --no-deploy=traefik,servicelb,metrics-server
extraAgentArgs: []
extraArgs:
- arg: --no-deploy=traefik,servicelb,metrics-server
nodeFilters:
- server:*
kubeconfig:
updateDefaultKubeconfig: true
switchCurrentContext: true
18 changes: 9 additions & 9 deletions .github/workflows/assets/3.yaml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
apiVersion: k3d.io/v1alpha2
apiVersion: k3d.io/v1alpha3
kind: Simple
image: docker.io/rancher/k3s:v1.21.2-k3s1
servers: 1
agents: 3
ports:
- port: 0.0.0.0:82:80
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:445:443
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:5055:53/udp
nodeFilters:
- agent[0]
- agent:0:direct
options:
k3d:
wait: true
timeout: "60s"
timeout: 1m0s
disableLoadbalancer: true
disableImageVolume: true
k3s:
extraServerArgs:
- --no-deploy=traefik,servicelb,metrics-server
extraAgentArgs: []
extraArgs:
- arg: --no-deploy=traefik,servicelb,metrics-server
nodeFilters:
- server:*
kubeconfig:
updateDefaultKubeconfig: true
switchCurrentContext: true
18 changes: 9 additions & 9 deletions .github/workflows/assets/4.yaml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
apiVersion: k3d.io/v1alpha2
apiVersion: k3d.io/v1alpha3
kind: Simple
# image: default k3s version
servers: 1
agents: 3
ports:
- port: 0.0.0.0:83:80
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:446:443
nodeFilters:
- agent[0]
- agent:0:direct
- port: 0.0.0.0:5056:53/udp
nodeFilters:
- agent[0]
- agent:0:direct
options:
k3d:
wait: true
timeout: "60s"
timeout: 1m0s
disableLoadbalancer: true
disableImageVolume: true
k3s:
extraServerArgs:
- --no-deploy=traefik,servicelb,metrics-server
extraAgentArgs: []
extraArgs:
- arg: --no-deploy=traefik,servicelb,metrics-server
nodeFilters:
- server:*
kubeconfig:
updateDefaultKubeconfig: true
switchCurrentContext: true
25 changes: 13 additions & 12 deletions .github/workflows/assets/default.yaml
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
apiVersion: k3d.io/v1alpha2
apiVersion: k3d.io/v1alpha3
kind: Simple
name: k3s-k8gb-disco2
servers: 1
agents: 1
kubeAPI:
hostIP: "0.0.0.0"
hostIP: 0.0.0.0
hostPort: "6443"
image: rancher/k3s:latest
image: docker.io/rancher/k3s:latest
network: nw03
labels:
- label: foo=bar
nodeFilters:
- loadbalancer
ports:
- port: 0.0.0.0:8443:443
nodeFilters:
Expand All @@ -26,13 +22,18 @@ env:
options:
k3d:
wait: true
timeout: "60s"
timeout: 1m0s
disableLoadbalancer: false
disableImageVolume: true
k3s:
extraServerArgs:
- --no-deploy=metrics-server
extraAgentArgs: []
extraArgs:
- arg: --no-deploy=metrics-server
nodeFilters:
- server:*
kubeconfig:
updateDefaultKubeconfig: true
switchCurrentContext: true
runtime:
labels:
- label: foo=bar
nodeFilters:
- loadbalancer
16 changes: 8 additions & 8 deletions .github/workflows/multi-cluster-on-isolated-networks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ jobs:
network: "nw01"
subnet-CIDR: "172.20.0.0/24"
args: >-
-p "80:80@agent[0]"
-p "443:443@agent[0]"
-p "5053:53/udp@agent[0]"
-p "80:80@agent:0:direct"
-p "443:443@agent:0:direct"
-p "5053:53/udp@agent:0:direct"
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2
Expand All @@ -31,12 +31,12 @@ jobs:
network: "nw02"
subnet-CIDR: "172.20.1.0/24"
args: >-
-p "81:80@agent[0]"
-p "444:443@agent[0]"
-p "5054:53/udp@agent[0]"
-p "81:80@agent:0:direct"
-p "444:443@agent:0:direct"
-p "5054:53/udp@agent:0:direct"
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- name: Cluster info
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/multi-cluster-registry.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
args: >-
--agents 1
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2
name: "Create 2nd k3d Cluster with Registry"
Expand All @@ -27,7 +27,7 @@ jobs:
args: >-
--agents 1
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- name: Cluster info
run: |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
args: >-
--agents 1
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-1-b
Expand All @@ -30,7 +30,7 @@ jobs:
args: >-
--agents 1
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2-a
Expand All @@ -42,7 +42,7 @@ jobs:
args: >-
--agents 1
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2-b
Expand All @@ -53,7 +53,7 @@ jobs:
args: >-
--agents 1
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- name: Cluster info
run: |
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/multi-cluster-two-piars-registry.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
--agents 1
--no-lb
--image docker.io/rancher/k3s:v1.21.2-k3s1
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-1-b
Expand All @@ -35,7 +35,7 @@ jobs:
--agents 1
--no-lb
--image docker.io/rancher/k3s:v1.21.2-k3s1
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2-a
Expand All @@ -50,7 +50,7 @@ jobs:
--agents 1
--no-lb
--image docker.io/rancher/k3s:v1.21.2-k3s1
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2-b
Expand All @@ -64,7 +64,7 @@ jobs:
--agents 1
--no-lb
--image docker.io/rancher/k3s:v1.21.2-k3s1
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- name: Cluster info
run: |
Expand Down Expand Up @@ -101,4 +101,3 @@ jobs:
env:
REGISTRY_PORT: 5001
run: ./run.sh test-registry

8 changes: 4 additions & 4 deletions .github/workflows/multi-cluster-two-piars.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
args: >-
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-1-b
Expand All @@ -29,7 +29,7 @@ jobs:
args: >-
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2-a
Expand All @@ -41,7 +41,7 @@ jobs:
args: >-
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2-b
Expand All @@ -52,7 +52,7 @@ jobs:
args: >-
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- name: Cluster info
run: |
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/multi-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,24 +14,24 @@ jobs:
with:
cluster-name: "test-cluster-1"
args: >-
-p "80:80@agent[0]"
-p "443:443@agent[0]"
-p "5053:53/udp@agent[0]"
-p "80:80@agent:0:direct"
-p "443:443@agent:0:direct"
-p "5053:53/udp@agent:0:direct"
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- uses: ./
id: test-cluster-2
name: "Create 2nd k3d Cluster"
with:
cluster-name: "test-cluster-2"
args: >-
-p "81:80@agent[0]"
-p "444:443@agent[0]"
-p "5054:53/udp@agent[0]"
-p "81:80@agent:0:direct"
-p "444:443@agent:0:direct"
-p "5054:53/udp@agent:0:direct"
--agents 3
--no-lb
--k3s-server-arg "--no-deploy=traefik,servicelb,metrics-server"
--k3s-arg "--no-deploy=traefik,servicelb,metrics-server@server:*"
- name: Cluster info
run: |
Expand Down
Loading

0 comments on commit 8781d81

Please sign in to comment.