73 Commits

Author SHA1 Message Date
Wouter Verlaek
bfa7b301b7
[ws-manager-mk2] Fix headless task failures (#17429) 2023-04-28 19:26:36 +08:00
Wouter Verlaek
c1e627a66f
[ws-manager-mk2] Improve reconcile err logging (#17419)
* [ws-manager-mk2] Improve reconcile err logging

* Update StopWorkspace err log

* Fix errors
2023-04-28 14:56:36 +08:00
Wouter Verlaek
ce04b77c29
[ws-manager-mk2] Maintenance continue reconciles (#17136) 2023-04-28 05:42:36 +08:00
Wouter Verlaek
96100e9975
[ws-manager-mk2] Always send OnReconcile events (#17376) 2023-04-26 00:08:46 +08:00
Thomas Schubart
dafcf19ded
[wsman-mk2] Set workspace class environment variables (#17316) 2023-04-21 19:43:42 +08:00
Manuel Alejandro de Brito Fontes
541f6f65c5
Remove unused PodSecurityPolicy feature (#17176) 2023-04-13 22:13:53 +02:00
Wouter Verlaek
06ec36b564
[ws-manager-mk2] Refactor metrics with EverReady condition (#17114)
* [ws-manager-mk2] Refactor metrics with EverReady condition

* Fix test, default failure message

* Add stop reason metric
2023-04-08 11:57:48 +02:00
Wouter Verlaek
f23737694a
[ws-manager-mk2] Extract headless task failure (WKS-18) (#17091)
* [ws-manager-mk2] Extract headless task failure

* Undo ready status change, refactored #17114
2023-04-03 10:25:43 +02:00
Wouter Verlaek
dc68610c0e
[ws-manager-mk2] Ignore container killed failures (#17118)
* [ws-manager-mk2] Ignore container killed failures

* ClusterRole + Binding
2023-03-31 23:31:41 +02:00
Pudong
24c401ab78
[ws-manager-mk2] support custom closed timeout (#16988)
* [ws-manager-mk2] support custom closed timeout

* Default to the RegularWorkspace timeout

* remove code

---------

Co-authored-by: Wouter Verlaek <wouter@gitpod.io>
2023-03-31 20:05:40 +02:00
Wouter Verlaek
c828d4176c
[ws-manager-mk2] Remember existing workspaces after a restart (#17066) 2023-03-29 20:43:39 +02:00
Thomas Schubart
697d81ecbf
[ws-manager-mk2] Introduce experimental mode (#17048)
* [installer] Add experimental mode for mk2

* [wsman-mk2] Use ExperimentalMode flag
2023-03-28 17:56:26 +02:00
Wouter Verlaek
c14a25cfdf
[ws-manager-mk2] Report content init/dispose failures (#17015) 2023-03-27 17:22:25 +02:00
Thomas Schubart
c5efa71b4d
[wsman-mk2] Emit event for timed out workspaces (#17003) 2023-03-23 17:38:16 +01:00
Wouter Verlaek
57840fc6ed
[ws-manager-mk2] Refactor maintenance mode to end at a timestamp (#16925)
* [ws-manager-mk2] Maintenance until

* Fix configmap

* Always show field

* Remove todo
2023-03-22 16:39:14 +01:00
Manuel Alejandro de Brito Fontes
5b30eb5b8c
Remove unused caCertSecret (#16793)
* Add trust.cert-manager.io for to bundle CA certificates

Signed-off-by: Manuel de Brito Fontes <aledbf@gmail.com>

* Configure CA volume and volumemount in components

* Update ws-manager golden files

* Deploy trust manager in preview

* Remove duplicated volume

* Update installer golden files

* Generate a bundle only for registry-facade

* Update golden files

* Fix initcontainer volume mounts

* Update golden files

* Fix registry-facade certificate

* Update golden files

* Disable skip_verify

* Enable force conflict with apply server side

Signed-off-by: Manuel de Brito Fontes <aledbf@gmail.com>

* Avoid random werft namespace errors

Signed-off-by: Manuel de Brito Fontes <aledbf@gmail.com>

---------

Signed-off-by: Manuel de Brito Fontes <aledbf@gmail.com>
2023-03-21 11:44:13 +01:00
Thomas Schubart
42a3602fce
[ws-manager-mk2] Emit events for workspaces and snapshots (#16907)
* [wsman-mk2] Emit workspace events

* [installer] Permissions for events

* [ws-man-mk2] Emit snapshot events

* [installer] Update render tests

* [wsman-mk2] Include review comments
2023-03-20 13:59:12 +01:00
Wouter Verlaek
95158eba38
[ws-manager-mk2] Don't dispose image builds (#16902) 2023-03-20 11:34:12 +01:00
Wouter Verlaek
3a561bf274
[ws-manager-mk2] Check empty ns, delete secrets before finalizer (#16900) 2023-03-20 11:32:12 +01:00
Thomas Schubart
ace513ad7e
[ws-manager-mk2] Refactor workspace status conditions (#16896)
* [wsman-mk2] Refactor conditions

* [wsman-mk2] Specify reason
2023-03-20 11:10:12 +01:00
Thomas Schubart
c800175c72
[ws-manager-mk2] Protect tokens (#16806)
* [wsman-mk2] Create token secret

* [installer] Fix casing for namespace type metadata

* [installer] Create secrets namespace

* [installer] Configure roles and bindings

* [installer] Move namespace constant to common pkg

* [installer] Create permissions for ws-daemon

* [wsman-mk2] Watch on multiple ns

* [ws-daemon] Use token secret

* [wsman-mk2] Remove secret from initializer

* [wsman-mk2] Test token secret

* [werft] Fix document index

* [installer] Update render tests

* [wsman-mk2] Fix imports

* [wsman-mk2] Ensure maintenance controller required permissions

* [wsman-mk2] Retry deleting secret

* [installer] Ensure objects in secrets namespace are only created with mk2 option
2023-03-15 12:57:07 +01:00
Wouter Verlaek
25220bb30b
[ws-manager-mk2] Maintenance mode (#16702)
* [ws-manager-mk2] Maintenance mode reconciler

* [ws-manager-mk2] Check for maintenance mode

* [ws-manager-mk2] Default to maintenance mode on startup

* [ws-manager-mk2] Disable maintenance on unmarshal failure
2023-03-09 17:25:45 +01:00
Wouter Verlaek
ee9ea036d7
[ws-manager-mk2] Fix stopped status (#16665) 2023-03-06 16:28:04 +01:00
Wouter Verlaek
6694cf138b
[ws-manager-mk2] Enable tracing, add debug logs (#16643) 2023-03-06 16:22:03 +01:00
Wouter Verlaek
1631a4a038
[ws-manager-mk2] Loadgen fixes, concurrent reconciliation (#16613)
* [ws-manager-mk2] Loadgen fixes, concurrent reconciliation

* [ws-manager-mk2] Update tests with content readiness

* Simplify content ready check

* Fix json tags

* Revert poll interval
2023-03-06 15:18:04 +01:00
Thomas Schubart
400be836fb
[ws-manager-mk2] Protect environment secrets (#16601)
* [installer] Configure RBAC access to secrets

* [wsman-mk2] Create environment workspace secret

* [wsman-mk2] Delete workspace secret after start/stop

* [ws-manager-mk2] Update tests

* [ws-manager-mk2] Remove poll
2023-03-06 12:42:03 +01:00
Wouter Verlaek
a9810d6a0a
[ws-manager-mk2] Fix race where pod gets recreated in Stopped phase (#16622)
* [ws-manager-mk2] Fix race where pod gets recreated in Stopped phase

* [ws-manager-mk2] Add pod creation logs

* Change to Patch
2023-03-02 13:27:59 +01:00
Wouter Verlaek
e07b0c8b77
[ws-manager-mk2] Refactor metric collection and add tests (#16585) 2023-03-01 12:16:58 +01:00
Wouter Verlaek
bec87139a9
[ws-manager-mk2] Remove headless field (#16611) 2023-03-01 12:14:59 +01:00
Thomas Schubart
730224aef6
[ws-manager-mk2] Reduce duplicate delete pod calls (#16579) 2023-02-27 12:07:57 +01:00
Thomas Schubart
1f89b92e1a
[ws-manager-mk2] Fix workspace container detection (#16418) 2023-02-27 11:47:56 +01:00
Thomas Schubart
12f3c91599
[ws-manager-mk2] Ensure workspace enters stopped (#16479) 2023-02-27 11:45:57 +01:00
Wouter Verlaek
df3e15a1d4
[ws-manager-mk2] Remove headless from status (#16530) 2023-02-23 17:36:53 +01:00
Wouter Verlaek
7440f00796
[ws-manager-mk2] Add Grafana dashboard (#16455)
* [ws-manager-mk2] Add Grafana dashboard

* [ws-manager-mk2] Add reconciliations by controller panel
2023-02-23 00:19:52 +01:00
Wouter Verlaek
7349d1cd3c [ws-manager-mk2] Timeout controller tests 2023-02-17 11:08:21 +01:00
Wouter Verlaek
02f323dcaf [ws-manager-mk2] Fix deployed condition being repeatedly set 2023-02-16 14:30:20 +01:00
Wouter Verlaek
00229da4af [ws-manager-mk2] Add finalizer on workspace, handle deletion 2023-02-15 11:27:19 +01:00
Wouter Verlaek
8fcec5e4f5 [ws-manager-mk2] Fix workspace URL 2023-02-15 10:55:19 +01:00
Thomas Schubart
ad3b05c064 [ws-manager-mk2] Support system environment variables 2023-02-15 08:22:19 +01:00
Thomas Schubart
de8ee028a2 [ws-manager-mk2] Support class|network limiting and PSI 2023-02-15 08:05:19 +01:00
Wouter Verlaek
e62c773362 [ws-manager-mk2] Aborted condition, grace period 2023-02-14 12:04:19 +01:00
Thomas Schubart
57fee90556 [ws-manager-mk2] Schedule on experimental nodes 2023-02-14 11:41:19 +01:00
Wouter Verlaek
468f7bf016 [ws-manager-mk2] Controller env tests 2023-02-13 22:08:18 +01:00
Wouter Verlaek
172c58c0eb [ws-manager-mk2] Workspace timeouts 2023-02-10 10:49:15 +01:00
Thomas Schubart
ab0ab235d3 [ws-manager-mk2] Ensure values are set despite update conflict 2023-02-09 12:30:14 +01:00
Wouter Verlaek
093338cca3 Increase envtest start/stop timeout 2023-02-08 16:47:46 +01:00
Wouter Verlaek
a4e0b11fe2 [ws-manager-mk2] Fix and enable controller tests 2023-02-08 16:47:46 +01:00
Wouter Verlaek
810e17508d [ws-manager-mk2] Extract ctrl utils to common-go 2023-02-07 11:19:45 +01:00
Wouter Verlaek
971c3d6412 [ws-manager-mk2] Implement MarkActive 2023-02-07 10:51:45 +01:00
Thomas Schubart
90fe8b3063 [ws-manager-mk2] Get location from initializer 2023-02-01 17:52:40 +01:00