Brian Downs
49073cd2ff
add timeouts around s3 operations
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 10:07:55 -07:00
Brian Downs
78067d4d95
update comments, remove unneeded code
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 10:07:48 -07:00
Brian Downs
605473e259
fix delete logic, update subcommand functionality
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 10:07:41 -07:00
Brian Downs
bfea9247cf
initial
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 10:07:33 -07:00
Brian Downs
f0a752ef80
move snapshot save into if nil check
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:54:13 -07:00
Brian Downs
80b1ca2586
move map nil check
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:53:58 -07:00
Brian Downs
e9bc6bdc09
initialize map if nil
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:53:52 -07:00
Brian Downs
59b52a157d
refactor snapshot storage processing logic
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:53:43 -07:00
Brian Downs
3a834aae59
change string interpolation var in error msg
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:53:29 -07:00
Brian Downs
574648ef6f
update error message with context about failure
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:53:21 -07:00
Brian Downs
b60ee806f5
add nodeName to etcd struct, update refs
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:53:13 -07:00
Brian Downs
a1220f7fc7
Add ability for node to save etcd snapshot state at start.
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:52:49 -07:00
Brian Downs
a74fb99037
Update snapshot local and S3 logic and supporting code.
...
* Add the collection of the snapshots to the retry logic.
* Remove node specific entries and collected entries to maps and
update the config map.
* Add node-name flag to the etcd-snapshot command and set in ENV.
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:52:16 -07:00
Brian Downs
86ecb79716
remove dirs from snapshot listing
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:52:11 -07:00
Brian Downs
2ca14a331e
remove unnecessary prefix:
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:52:04 -07:00
Brian Downs
a711f6a365
export needed function to create core factory
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:57 -07:00
Brian Downs
62bbef7253
update struct field doc comment and get basename on s3 obj
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:49 -07:00
Brian Downs
83ae76fe8d
update data structure and account for possible race in start
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:42 -07:00
Brian Downs
4c57fad5a1
update doc comment
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:35 -07:00
Brian Downs
297d80a924
remove unnecessary error condition
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:27 -07:00
Brian Downs
4e90846599
add node name to s3 structure data
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:20 -07:00
Brian Downs
a831b8e611
add location comment
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:13 -07:00
Brian Downs
d6378e5901
add addtional log entry
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:51:06 -07:00
Brian Downs
77caab3c34
update retention
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:50:58 -07:00
Brian Downs
b3e84c8862
code clean up, simplification, etc.
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:50:52 -07:00
Brian Downs
a846957a47
update func sig
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:50:44 -07:00
Brian Downs
9882eb0887
update vendor and config map name
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:50:30 -07:00
Brian Downs
a6f64cc73d
update node name in s3 files
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:48:54 -07:00
Brian Downs
10f0a7908a
add configmap save logic
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:48:45 -07:00
Brian Downs
977d7923dd
Add ability to list snapshots.
...
This adds the ability to list snapshots stored locally and in S3 and
their respective metadata.
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-06-29 09:48:38 -07:00
Derek Nola
5d0a12a616
Update to v1.20.8 ( #3477 )
...
* Update to v1.20.8
* Fix comment typo that was breaking tests
Signed-off-by: root <derek.nola@suse.com >
2021-06-17 19:34:10 -07:00
Brad Davidson
245f27e2b2
Handle conntrack-related sysctls in supervisor agent setup
...
(cherry picked from commit 7e175e8ad4 )
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2021-05-19 01:03:00 -07:00
MonzElmasry
e939805a5e
change --disable-apiserver flag
...
Signed-off-by: MonzElmasry <menna.elmasry@rancher.com >
2021-05-13 00:25:07 +02:00
MonzElmasry
77390596e6
add cloud controller manager fixes from master
...
Signed-off-by: MonzElmasry <menna.elmasry@rancher.com >
2021-04-16 00:09:09 +02:00
Brian Downs
1521e3b085
Resolve local retention issue when S3 in use.
...
Remove early return preventing local retention policy to be enforced
resulting in N number of snapshots being stored.
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-04-14 12:11:32 -07:00
Brian Downs
221c9ae589
add hidden attribute to disable flags
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-04-13 16:29:51 -07:00
Brian Downs
9a572ecae0
delete nocluster file and remove build tag
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-04-13 16:29:51 -07:00
Brian Downs
3f73665131
remove hidden attribute from cluster flags and related code
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-04-13 16:29:51 -07:00
Brian Downs
29f6275aae
add etcd s3 secret and access key flags and env vars to secret data
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-04-12 15:53:12 -07:00
Brian Downs
c09142a3a7
put etcd bootstrap save call in goroutine and update comment
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-03-18 12:52:03 -07:00
Brian Downs
62839b302a
remove duplicate method
...
Signed-off-by: Brian Downs <brian.downs@gmail.com >
2021-03-16 11:24:56 -07:00
Brian Downs
0167f86f5d
Have Bootstrap Data Stored in etcd at Completed Start ( #3038 )
...
* have state stored in etcd at completed start and remove unneeded code
Signed-off-by: Brian Downs <brian.downs@gmail.com >
(cherry picked from commit 7c99f8645d )
2021-03-15 16:04:10 -07:00
Brian Downs
1da86eaa0b
Etcd Snapshot/Restore to/from S3 Compatible Backends ( #2902 )
...
* Add functionality for etcd snapshot/restore to and from S3 compatible backends.
* Update etcd restore functionality to extract and write certificates and configs from snapshot.
Signed-off-by: Brian Downs <brian.downs@gmail.com >
(cherry picked from commit 4d1f9eda9d )
2021-03-15 16:04:04 -07:00
Brian Downs
0a3360fc6f
Add ability to perform an etcd on-demand snapshot via cli ( #2819 )
...
* add ability to perform an etcd on-demand snapshot via cli
Signed-off-by: Brian Downs <brian.downs@gmail.com >
(cherry picked from commit 13229019f8 )
2021-03-15 16:02:47 -07:00
Chris Kim
bc400f5396
Define a Controllers and LeaderControllers on the server config ( #3053 )
...
Signed-off-by: Chris Kim <oats87g@gmail.com >
2021-03-12 07:27:42 -08:00
Brad Davidson
01fc0249af
Log clearer error on startup if NPC cannot be started
...
Servers should always be upgraded before agents, but generally this
isn't required because things are compatible between versions. In this
case we're OK with failing closed if the user upgrades out of order, but
we should give a clearer message about what steps are required to fix
the issue.
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
(cherry picked from commit 31bbae1eb1 )
2021-03-11 12:13:56 -08:00
Hussein Galal
b0c0d372b8
[release-1.20] Add disable components flags ( #3019 )
...
* Add disable flags for control components (#2900 )
* Add disable flags to control components
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* golint
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* more fixes
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* fixes to disable flags
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* Add comments to functions
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* Fix joining problem
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* more fixes
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* golint
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* fix ticker
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* fix role labels
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* more fixes
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* remove etcd member if disable etcd is passed
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* update dynamiclistener
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* change error to warn when removing self from etcd members
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
* Mark disable components flags as experimental
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
2021-03-05 00:04:48 +02:00
Brad Davidson
6e768c301e
Use appropriate response codes for authn/authz failures
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2021-02-09 16:28:20 -08:00
Brad Davidson
374271e9a0
Collect IPs from all pods before deciding to use internal or external addresses ( #2909 )
...
* Collect IPs from all pods before deciding to use internal or external addresses
@Taloth correctly noted that the code that iterates over ServiceLB pods
to collect IP addresses was failing to add additional internal IPs once
the map contained ANY entry from a previous node. This may date back to
when ServiceLB used a Deployment instead of a DaemonSet, so there was
only ever a single pod.
The new behavior is to collect all internal and external IPs, and then
construct the address list of a single type - external if there are any,
otherwise internal.
https://github.com/k3s-io/k3s/issues/1652#issuecomment-774497788
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
Co-authored-by: Brian Downs <brian.downs@gmail.com >
2021-02-09 16:26:57 -08:00
Brad Davidson
e06119729b
Improve handling of comounted cpu,cpuacct controllers ( #2911 )
...
* Improve handling of comounted cpu,cpuacct controllers
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2021-02-09 16:12:58 -08:00