John Gardiner Myers
0d1c6371d6
Get VFSContext from Factory in channels
2023-07-15 15:32:50 -07:00
Ciprian Hacman
ac05e3e332
Clear the errors if the apply after prune succeeds
2023-07-05 13:23:26 +03:00
Ciprian Hacman
59b7653cc3
Update min versions for kOps v1.28
2023-06-20 08:11:21 +03:00
Ole Markus With
74a6a5a319
Always try to prune an addon even if applying updates fail
2023-03-04 07:18:53 +01:00
justinsb
817c1e63b3
FindKeyset can return nil
...
We had missed a case in nodeup; add a Context argument to force us to
revisit the codepaths.
2022-12-24 16:12:21 -05:00
Ole Markus With
43be10020c
Use enums for needsRollingUpdate in the channels API
2022-12-20 22:11:56 +01:00
Ole Markus With
27e206a264
Expose channels through kops toolbox cli
...
Make the channels apply commmand a bit more clear
Update cmd/kops/toolbox_addons.go
Co-authored-by: Ciprian Hacman <ciprian@hakman.dev>
Update cmd/kops/toolbox_addons.go
Co-authored-by: Ciprian Hacman <ciprian@hakman.dev>
fix docs
2022-12-04 15:47:09 +01:00
Ciprian Hacman
8f79c9bd68
Replace fi.Bool/Float*/Int*/String() with fi.PtrTo()
2022-11-19 03:45:22 +02:00
Ole Markus With
392ececda7
Let kOps take ownership of any field currently owned by kubectl
2022-10-01 08:58:26 +02:00
Justin SB
6184f12861
Introduce applylib
...
A number of projects need a library for applying objects. While we
are figuring out exactly what functionality is needed, we are using a
copy-and-paste approach.
Introduce applylib here also, and add the create-or-update
functionality that we want here.
2022-08-17 08:10:20 -04:00
Kubernetes Prow Robot
7035526204
Merge pull request #14135 from hakman/go-1.19.0
...
Update Go to v1.19.0
2022-08-17 02:40:55 -07:00
Ciprian Hacman
cb99db0757
Run make goimports
2022-08-17 07:03:33 +03:00
Ole Markus With
381ceb1d14
Revert back to using kubectl in channels
...
Introduces an Applier interface and keeps the custom client based implementation
2022-08-14 13:06:17 +02:00
Peter Rifel
3eb30853f7
Fix typo in channels error message
2022-08-02 17:21:08 -05:00
Ole Markus With
70181ec3b3
Remove --files flag from channels and make single arg mandatory
2022-08-02 20:27:36 +02:00
Kubernetes Prow Robot
8ec65a2ab6
Merge pull request #14075 from olemarkus/merge-factory
...
Merge cmd factories
2022-07-30 22:18:27 -07:00
Ole Markus With
0bd3160bbc
Merge channels and kops cli factories
2022-07-31 06:32:57 +02:00
Ole Markus With
820bba41cf
Use SSA for updating addon channel objects
2022-07-30 11:21:09 +02:00
Justin SB
bb1070269a
Applier should be more tolerant of errors
...
We also aim to be a little stricter about invalid input
(e.g. namespace specified for cluster-scoped objects).
2022-07-11 11:09:29 -04:00
Ole Markus With
389d7c1214
Set UserAgent to kops on the REST config
2022-07-02 16:13:30 +02:00
Ole Markus With
cb96d39804
Use dynamic client for applying channels manifest rather than calling kubectl
2022-07-02 16:13:27 +02:00
Ole Markus With
ba67287540
Apply PKI even if addon fails
2022-06-29 08:12:56 +02:00
Ole Markus With
699653d00b
Replace manifests after apply
2022-06-21 13:57:33 +02:00
Ciprian Hacman
6a24dc2dbc
Revert "Use kubectl replace instead of apply when updating addons"
...
This reverts commit 18c5d184e7 .
2022-06-10 07:19:58 +03:00
Ole Markus With
db5cee1320
Channels to have exit status 1 on apply failure
2022-06-08 10:32:01 +02:00
Ole Markus With
18c5d184e7
Use kubectl replace instead of apply when updating addons
2022-06-04 12:12:00 +02:00
Ole Markus With
ce2e877aeb
Remove bazel files from vendor
2022-04-12 13:29:03 +02:00
Ole Markus With
5f6b480f81
Update cert-manager dependency to 1.8.0
2022-04-10 12:39:47 +02:00
Ole Markus With
e128cc7f5d
Preload channel versions from namespaces
...
Avoids loading the NS multiple times per installed addon
2022-01-05 10:38:26 +01:00
Ciprian Hacman
ea7df00719
Run hack/update-gofmt.sh
2021-12-01 22:39:50 +02:00
Eng Zer Jun
425173ae9f
refactor: move from io/ioutil to io and os packages
...
The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil . This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2021-11-12 15:37:18 +08:00
Ole Markus With
e387ddee12
Use server-side apply for addons. Idenity as kops
2021-10-23 08:16:38 +02:00
justinsb
c34fd83365
Add SystemGeneration to channel version tracker
...
This allows us to reapply a manifest when we introduce new
functionality, such as pruning.
Otherwise an old version can apply the manifest, mark the manifest as
applied, and we won't reapply.
2021-10-15 17:47:13 -04:00
justinsb
df2c55917b
More logging from pruning
2021-10-15 17:47:13 -04:00
justinsb
0594eee373
pruning: Allow specification of FieldSelector
...
FieldSelector allows for filtering by name (as well as a few other
attributes). Though we aren't using this today, filtering by name is
something we've discussed as being valuable in future, and by putting
it in the API now we avoid version skew problems should we need to
introduce it in future.
2021-10-15 17:47:13 -04:00
justinsb
454c47f92b
Support pruning in channels command
...
We let the addon specify exactly what should be pruned; this approach
is a little more verbose but we're likely generating this
automatically in the common case anyway.
In return for the verbosity, we can likely handle more future cases
and edge cases (for example removing objects that aren't labelled or
are in the wrong namespace).
2021-10-15 17:47:13 -04:00
Ole Markus With
e7a5437a34
Add fixed version to all addons
...
This will make also older channels trigger addon updates
2021-09-30 15:25:29 +02:00
Kubernetes Prow Robot
8276ec1001
Merge pull request #12064 from hakman/legacy_addons
...
Disallow the use of legacy addons
2021-08-07 13:09:30 -07:00
John Gardiner Myers
03434509e2
Use SHA-256 for manifest hashes
2021-08-01 16:37:01 -07:00
Ciprian Hacman
8bbc88eb2e
Disallow the use of legacy addons
2021-07-31 05:33:26 +03:00
Ole Markus With
0a43080957
Continue if a single addon fails to be applied
2021-07-06 08:31:49 +02:00
Ciprian Hacman
2f3bad686a
Remove version from addons
2021-06-25 19:25:01 +03:00
John Gardiner Myers
a8b9aa13eb
Don't include irrelevant bootstrap addons
2021-06-24 20:34:17 -07:00
Ole Markus With
fded614baa
Add some tests around channel adding needs-update annotation
2021-05-25 15:15:32 +02:00
Ole Markus With
0dc9cd44e6
Set SAN for addon CAs
2021-04-27 09:27:57 +02:00
Ole Markus With
daabfc2111
Don't set NeedUpdate on first addon install
2021-04-18 16:31:37 +02:00
Peter Rifel
21389c8276
Cleanup some nodeup & protokube logging
...
Also log a channels error that we're seeing on flatcar to help with troubleshooting
2021-03-14 21:49:35 -05:00
Ole Markus With
d41f68c6ef
Make channels create PKI for addons that needs it
2021-01-30 09:01:33 +01:00
Ole Markus With
f4e3dd3e26
Rename NeedUpdate struct to NeedsRollingUpdate
2020-11-16 19:48:18 +01:00
Ole Markus With
2659a30280
Make get instances respect needs-update annotation
...
Make it possible for addons to set needs-update annotation
Use onDelete update strategy for cilium and set needs-update annotation
Rename node roles
2020-11-16 08:26:17 +01:00