iwilltry42
9c9f49646e
MasterLoadBalancer: add nodefilter & extra treatment
...
- masterlb is now an extra part of the cluster spec
- ports can now be attached to masterlb by using the 'loadbalancer'
nodefilter
- all ports exposed on the masterlb will be proxied to all master nodes
(on the same port)
2020-05-11 10:57:54 +02:00
iwilltry42
3071ec5755
createCluster: add --no-lb flag to disable the load balancer
...
- does not create the load balancer node
- exposes the API port on the first master node (master-0)
2020-05-09 13:02:02 +02:00
iwilltry42
c6564801f3
getKubeconfig: always return output filepath
2020-05-04 18:26:59 +02:00
iwilltry42
05f2fc1f66
docs: add more command information
2020-04-27 17:30:51 +02:00
iwilltry42
5b637126d7
createCluster: add --update-kubeconfig flag
...
- enables wait-for-master
- calls GetAndWriteKubeConfig after successful cluster creation to
update the default kubeconfig with the new cluster's details
- does NOT automatically switch the current-context
- outputs a different line saying, that you can switch context now
2020-04-24 14:02:38 +02:00
iwilltry42
6677f82d5b
getKubeConfig: consider the KUBECONFIG env var when updating default kubeconfig
2020-04-24 07:52:23 +02:00
iwilltry42
5b1e723fdd
createCluster: add more detailed description and info regarding api port
2020-04-23 14:51:10 +02:00
iwilltry42
091190447c
createCluster: fix final print after cluster creation on windows (different setting of env vars)
2020-04-23 14:43:08 +02:00
iwilltry42
5121ef80a5
create/start/stop cluster: fix how Master-LoadBalancer is treated
...
- always include the k3d.role label and use LoadBalancerRole for
masterlb
- start masterlb last when starting a stopped cluster so it won't fail
2020-04-22 13:18:26 +02:00
iwilltry42
c51ec003bd
createCluster/network: add basic support for hostnetwork mode in docker
2020-04-16 10:07:19 +02:00
iwilltry42
1b7f5c5f78
createCluster/timeout: use context to handle cancellation
...
With the updated cobra depencendy, we're now passing a context
from the cmd to the called functions.
When creating a cluster, one can pass a Duration to the --timeout
flag, which will create a new context with a timeout.
In the two blocking functions, where we're waiting for the master nodes
(initializing master nodes and "normal" master nodes), we're now
checking for the context cancellation as well, which may be caused
by the timeout.
2020-04-15 11:52:22 +02:00
iwilltry42
80d1c5c2de
initialize proper timeout flag
2020-04-15 10:43:53 +02:00
Thorsten Klein
d8eb206e44
Merge pull request #218 from rancher/feature/master-loadbalancer
...
[v3/Feature] Add cluster-loadbalancer
2020-04-15 07:34:39 +02:00
iwilltry42
77bddc4dd0
create/cluster: check if cluster with given name exists
...
To prevent accidental rollbacks of existing clusters with the same name,
we now check if a cluster with the chosen name exists first.
If it exists, we don't do anything at all and just error our
2020-04-14 19:58:21 +02:00
iwilltry42
b1d71dfa0f
create/node: default clusterName for --cluster flag
2020-04-14 19:28:07 +02:00
iwilltry42
244732bb1c
add todo
2020-04-08 17:49:02 +02:00
iwilltry42
a24d6f864e
Proxy: deploy a configurable nginx proxy in front of the cluster
...
Up to now, we exposed ports on single master nodes, which is quite
inconvenient on user side and troublesome on development side.
Now, we're creating a proxy container which exposes a single port
and proxies traffic to all master nodes.
Currently, this only works with 'k3d create cluster' and won't
update the proxy when using 'k3d create node --role master'.
2020-04-08 17:45:27 +02:00
iwilltry42
164d850321
CLEANUP: clean TODOs in createCluster
2020-04-06 16:51:09 +02:00
iwilltry42
a7ef585e12
createCluster: allow 0 or 1 arg
...
Allow 0 or 1 argument for k3d create cluster.
If 0, then we'll use the default cluster name.
2020-04-06 16:34:32 +02:00
iwilltry42
7005f8182a
validate clustername on create and use global runtime variable
2020-03-29 19:39:41 +02:00
iwilltry42
2d35895edc
move no-lb setting to createClusterOpts
2020-02-01 14:37:57 +01:00
iwilltry42
3ff51a0446
move no-lb setting to createClusterOpts
2020-02-01 14:32:04 +01:00
iwilltry42
2b674cb4e3
use createClusterOpts
2020-02-01 14:10:14 +01:00
iwilltry42
5500872544
Fatal out when using portmapping without node filter on a cluster with more than one node
2020-02-01 13:33:07 +01:00
iwilltry42
55646119c2
CLI: rollback if cluster creation failed
2020-01-28 15:06:07 +01:00
iwilltry42
b8ac954d69
implement --wait asynchronously
2020-01-28 10:28:30 +01:00
iwilltry42
a25d1d346a
add clusterCreateOpts flag struct and implement extra args for k3s server/agent
2020-01-15 09:29:35 +01:00
iwilltry42
bc49f197d9
cleanup and prepare for push to rancher/k3d
2020-01-05 21:16:31 +01:00
iwilltry42
f571ff3143
getk3sversion
2020-01-02 14:32:25 +01:00
iwilltry42
644b369b60
switch from K3S_CLUSTER_SECRET to K3S_TOKEN and use exact matching to get node containers by name and make --cluster flag required when creating a new node
2019-12-19 11:50:25 +01:00
iwilltry42
fd4b803681
start fixing createNode
2019-12-12 19:14:26 +01:00
iwilltry42
8aad61a39a
improve usage texts
2019-12-12 08:20:24 +01:00
iwilltry42
1a91401d19
start with --wait flag
2019-12-05 11:23:56 +01:00
iwilltry42
68609ec3a0
add info text after cluster creation
2019-12-05 09:55:24 +01:00
iwilltry42
ef2907de41
replace 127.0.0.1:6443 in kubeconfig as well
2019-12-05 09:33:22 +01:00
iwilltry42
52b23adec9
v1.0.0 as default version
2019-12-05 09:15:29 +01:00
iwilltry42
11b937a910
implement load images command
2019-12-04 14:54:58 +01:00
iwilltry42
e6d7726ffb
add image volume
2019-12-04 08:19:42 +01:00
iwilltry42
4e24521c0d
disable external datastore option for now
2019-11-26 17:07:23 +01:00
iwilltry42
189e430f90
fix port collisions due to default exposed port on master nodes
2019-11-22 18:46:52 +01:00
iwilltry42
bd39336b29
init ha setup with cluster-init
2019-11-20 21:38:59 +01:00
iwilltry42
7185a160c0
init new flags
2019-11-20 20:37:52 +01:00
iwilltry42
e2834f5320
fix error when no filter is set for single master api port
2019-11-11 12:45:28 +01:00
iwilltry42
5851da3ef3
start coupling network to clusters
2019-11-11 11:14:54 +01:00
iwilltry42
1ca9193776
add warning for multi-master setups
2019-11-11 09:33:41 +01:00
iwilltry42
45cc1ed57b
--api-port implementation
2019-11-11 09:32:28 +01:00
iwilltry42
7827840e64
start apiport stuff
2019-11-08 18:12:23 +01:00
iwilltry42
7098be1693
initial version of --port flag
2019-11-08 14:21:21 +01:00
iwilltry42
5ab8d5b50d
init --port flag implementation
2019-11-07 16:15:32 +01:00
iwilltry42
77ed3d3669
init --port flag implementation
2019-11-07 16:15:18 +01:00