109 Commits

Author SHA1 Message Date
Pudong
81ff3d16e4
[ws-manager-mk2] redact log (#18906)
* update to logrusr v4

* Add DeepCopyStruct to scrubber

* use DeepCopyStruct to scrub log

* mark wrokspace.stauts.url redact
2023-10-16 13:48:23 +03:00
Aleksandar
5dc4998b45
[eng-874] workspace creating time metric (#18916)
* [eng-874] workspace creating time metric

* calculate creating time from ts, add tests

* rm unused field

* copy pasta

* wrong phase
2023-10-13 13:33:21 +03:00
Manuel Alejandro de Brito Fontes
258651f923
Filter subscriber reconciler events (v2) (#18696)
* Filter subscriber reconciler events (v2)

* Ignore LastActivity
2023-09-12 20:54:52 +02:00
Wouter Verlaek
9ff81ee69e
Add maintenance metric (#18703) 2023-09-12 13:25:52 +02:00
Wouter Verlaek
2ac49194c6
Revert "Filter subscriber reconciler events (#18660)" (#18694)
This reverts commit 9470fb880093522021c1eaeecfb0373d087c39c3.
2023-09-11 11:28:09 +02:00
Manuel Alejandro de Brito Fontes
9470fb8800
Filter subscriber reconciler events (#18660)
* Filter subscriber reconciler events

* Notify changes in the port visibility

* Switch to reflect.DeepEquals

* Address feedback
2023-09-06 16:33:04 +02:00
Manuel Alejandro de Brito Fontes
887a8b55e4
Avoid ws-manager-mk2 metrics duplication (#18625) 2023-09-04 19:44:01 +02:00
Manuel Alejandro de Brito Fontes
7909192715
Reduce ws-manager-mk2 logs verbosity (#18626) 2023-09-04 15:41:01 +02:00
Manuel Alejandro de Brito Fontes
63c0c26c32
Remove SetControllerReference duplication (#18652) 2023-09-04 15:10:01 +02:00
Manuel Alejandro de Brito Fontes
687f337899
Enable leader election in ws-manager-mk2 (v3) (#18539)
* Enable leader election in ws-manager-mk2

* Update go modules

* Move workspace activity to CRD

* Remove workspace activity

* Cleanup

* Update ws-manager-mk2 CRD

* Cleanup

* Restore lastActivity logic

* TEST

* Disable observability

* Start the grpc server after leader election

* Bount the source of subscribers to an informer

* Cleanup

* Avoid deepCopy

* Remove goroutine to execute OnReconcile

* Refactor last activity to be consistent acrtoss the controllers

* Address feedback
2023-08-26 22:28:52 +02:00
Wouter Verlaek
bf3d548266
[ws-manager-mk2] Scrub status fields, add vscode launch.json (#18595)
* [ws-manager-mk2] Scrub status fields, add vscode launch.json

* Fix scrubber panic on unexported pointer
2023-08-25 13:00:51 +02:00
Manuel Alejandro de Brito Fontes
7e3ccd1197
Revert "Enable leader election in ws-manager-mk2 (#18511)" (#18537)
This reverts commit 2838b782309bb22b9341b2cf7ead718fc34bcba8.
2023-08-17 13:02:43 +02:00
Manuel Alejandro de Brito Fontes
2838b78230
Enable leader election in ws-manager-mk2 (#18511)
* Enable leader election in wa-manager-mk2

* Switch to four parallel tests

* Cleanup

* Update activity started time after leader election

* Count maintenance test failures

* Wait before updating the activity started time
2023-08-17 11:13:43 +02:00
Kyle Brennan
34b4602286
[ws-manager-mk2] remove experimental mode feature (#18513)
* [installer] remove experimental mode

* [ws-manager-mk2] remove experimental node selector

* [ws-manager-api] remove ExperimentalMode from configuration

* Add `ws-manager-api` to vscode workspace

* [preview] remove experimental & bump deps

Depends on https://github.com/gitpod-io/gitpod-packer-gcp-image/pull/246

* [preview] LocalStorageCapacityIsolation is GA, no needed as a gate in 1.27
2023-08-15 06:37:41 +02:00
Kyle Brennan
fb9e503943
[ws-manager-mk2] test create w/o git config (#18475) 2023-08-10 21:25:36 +02:00
Christian Weichel
fedfc4adbe
Make Git env vars independent of custom certs (#18474) 2023-08-10 00:08:35 +02:00
Manuel Alejandro de Brito Fontes
de4bbbea1c
Add a new trust bundle for custom SSL certificates (#18450)
* Add a new trust bundle for custom SSL certificates

* Mount the customer certificate in the workspace

* Use the custom certificate in components

* Cleanup

* Set env variables and mount the crt in a different file

* rename custom ca cert file name

* Fix the filename in env vars

* Enable custom SSL certificate conditionally

---------

Co-authored-by: nandajavarma <nandaja.varma@gmail.com>
2023-08-08 16:46:34 +02:00
Manuel Alejandro de Brito Fontes
8c6d8e28f3
Update dependencies (#18362)
* Update k8s dependencies to v1.27.3

* Update opencontainers/runtime-spec to v1.1.0

* Update controller runtime to v0.15.0

* Update go modules

* Fix build

* Cleanup

* Fix ws-manager e2e tests
2023-07-27 23:34:29 +08:00
Thomas Schubart
20164cbb4a
[wsman-mk2] Simplify condition checking (#17961) 2023-06-17 22:59:07 +08:00
Thomas Schubart
e4688a23a7
[ws-manager-mk2] Configure max workspace lifetime (#17767)
* [wsman-api] Add maximum lifetime to workspace request

* [wsman-api] Add maximum lifetime to workspace CRD

* [wsman] Set maximum lifetime during workspace start

* [wsman] Check custom max lifetime

* [wsman-api] Fix conflicting raw proto

* [wsman-mk2] Test custom max lifetime
2023-06-12 19:25:02 +08:00
Thomas Schubart
e1ddb2e5cc
[ws-manager-mk2] Test prebuilds and imagebuilds (#17899)
* [ws-daemon] Test prebuilds and imagebuilds

* [wsman-mk2] Ensure restore metrics are recorded
2023-06-12 16:58:02 +08:00
Wouter Verlaek
d41a38ba83
[ws-manager-mk2] Log conflict errors as info (#17840)
* [ws-manager-mk2] Log conflict errors as info

* Fix error field

* Requeue after small delay on conflict
2023-06-08 15:54:58 +08:00
Thomas Schubart
daef337abc
[wsman-mk2] Improve error message when removal of finalizer fails (#17749) 2023-05-25 23:47:59 +08:00
Thomas Schubart
a1d2d66d99
[wsman-mk2] Log workspace failure reason (#17752) 2023-05-25 23:43:59 +08:00
Wouter Verlaek
8861acb8a3
[ws-manager-mk2] Remove maintenance CM from installer (#17693) 2023-05-23 17:05:57 +08:00
Wouter Verlaek
da50b8ceb6
[ws-manager-mk2] Cleanup and fail workspaces when node disappears (#17599)
* [ws-manager-mk2] Cleanup and fail workspaces when node disappears

* Cache nodes

* Fix test, and reconcile ws when node gets deleted
2023-05-15 22:53:00 +08:00
Manuel Alejandro de Brito Fontes
09a354264d
Increase workspace TerminationGracePeriodSeconds to avoid issues of node removals (#17586) 2023-05-13 03:14:57 +08:00
Wouter Verlaek
85324b6951
[ws-manager-mk2] Refactor lastActivity (#17548) 2023-05-11 15:29:56 +08:00
Wouter Verlaek
c97d1f7e25
[ws-manager-mk2] Startup failures exclude StoppedByRequest (#17495)
* [ws-manager-mk2] Startup failures exclude StoppedByRequest

* Fix test
2023-05-09 20:28:50 +08:00
Thomas Schubart
81a6623ac3
[wsman-mk2] Ensure stop reason is logged (#17517) 2023-05-05 23:21:43 +08:00
Thomas Schubart
feb7a1fc6d
[wsman-mk2] Log workspace startup time (#17486) 2023-05-03 21:34:41 +08:00
Thomas Schubart
f77c23605b
[wsman-mk2] Schedule on non experimental nodes (#17481)
* [wsman-mk2] Schedule on non experimental nodes

* [wsman-mk2] Remove experimental label from preview nodes
2023-05-03 19:43:41 +08:00
Thomas Schubart
a289f08c5e
[wsman-mk2] Use ide and content for workspace readiness (#17449) 2023-05-03 00:18:40 +08:00
Wouter Verlaek
17f39cfe68
[ws-manager-mk2] Fix prebuild start failure false positives (#17465) 2023-05-03 00:17:41 +08:00
Wouter Verlaek
09a1586103
[ws-manager-mk2] Fix abort prebuild failure (#17451)
* [ws-manager-mk2] Fix abort prebuild failure

* Fix: don't set empty phase in extractFailure
2023-05-02 18:02:40 +08:00
Thomas Schubart
f78093f858
[wsman-mk2] Log reconcilliations (#17434) 2023-05-01 16:00:39 +08:00
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