Commit Graph
219 Commits
Author SHA1 Message Date
ec47195944 Linting adjustment for comment-space complaint (#13280)
Co-authored-by: Gus Luxton <gus@goteleport.com>
Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>
2022-09-15 19:05:38 +00:00
c67130052f helm: Add conditional creation of serviceAccount (#16337 and #11895)
Add conditional creation of `serviceAccount` in both `teleport-cluster` and `teleport-kube-agent` charts.

Signed-off-by: Hugo Hervieux <hugo.hervieux@goteleport.com>
Co-authored-by: nickolanick <biliaievnk@gmail.com>
Co-authored-by: Gus Luxton <gus@goteleport.com>
Co-authored-by: Mykola Biliaiev <mykola@firebolt.io>
2022-09-13 12:25:19 +00:00
Hugo Shaka 0290c671ed helm: support Kubernetes 1.25 (#16243)
Check if PodSecurityPolicy resources are supported before attempting to
deploy one. See https://kubernetes.io/docs/reference/using-api/deprecation-guide/#psp-v125
2022-09-12 20:30:30 +00:00
Logan Davis 6cbc9e1142 Update helm chart snapshots and tests for amazon ECR Public (#15355) 2022-08-23 16:03:40 +00:00
Hugo Shaka 65e861daeb Stop validating schema for labels in k8s operator (#15206)
* Stop validating schema for labels (#15204)
* operator: support receiving invalid TeleportRole CRs

This PR makes the controller-runtime manager decode TeleportRole
resource in an unstructured object. This avoid errors during decoding.
The resource is later decoded as a TeleportRole, with proper error
handling.
2022-08-17 03:18:17 +00:00
Hugo Shaka 82c520c818 helm: allow to disable local auth in teleport-cluster chart (#13827)
Fixes #12974

This commit introduces a new `authentication` value controlling:
- the authentication type (previously `authenticationType`)
- the second-factor (previously under `authenticationSecondFactor`)
- if local auth is enabled (new feature)
- the connector name (new feature)
- the locking mode (new feature)

If previous values `authenticationType` and `authenticationSecondFactor`
are specified we'll prefer them for backward compatibility.
2022-08-16 22:38:11 +00:00
Hugo Shaka f8be9cb6be helm: Add support for mounting existing TLS root CA (#13671)
* helm: Add support for mounting existing TLS root CA #12594
* Document per-database CA trust
2022-08-03 16:23:40 +00:00
Hugo Shaka 5add07799d helm: configure dynamoDB autoscaling in teleport-cluster (#13808)
* helm: configure dynamoDB autoscaling in teleport-cluster (#12046)
* Clarify best practices around DynamoDB autoscaling
2022-08-02 15:11:24 +00:00
Tiago Silva 40abd14635 Kubernetes Secret storage for Agent's Identity (#13942)
This MR introduces Kubernetes Secret storage for Teleport Kubernetes Agent state.

When running Teleport Agent inside a Kubernetes cluster where TELEPORT_REPLICA_NAME and KUBE_NAMESPACE exist, the agent will store identities and states in a Kubernetes Secret instead of local storage.

Otherwise, if the above environment variables are not present or not in Kubernetes, the agent persists state in SQLite.

Notes:

Fresh installs will enable the Kubernetes Secret Storage by default.
If PV storage is configured, the agent will store its identity in a Secret and use the PV for non-identity objects.
If the operator is upgrading from an existing release that didn't support Secret storage, the Helm chart will convert the objects to enable Kube Secret Storage. If the current object is a Deployment, the Helm chart installs a new Statefulset side by side and will trigger a Helm hook that is responsible for deleting the Deployment once Statefulset pods are healthy. Otherwise, if upgrading from a Statefulset the agent will read the credentials stored in PV and move them into Kube Secret.

Implementation of #12958
Related to #5585
2022-07-29 13:21:51 +00:00
Hugo Shaka 290b34f3be helm: Deploy CRDs when the operator is enabled (#14942)
* helm: Deploy CRDs when the operator is enabled
2022-07-28 17:05:11 +00:00
Hugo Shaka b3fd61790b helm: configure session recording in teleport-cluster (#13705)
* helm: configure session recording in teleport-cluster (#13543)
* Update docs/pages/setup/helm-reference/teleport-cluster.mdx
2022-07-28 15:51:25 +00:00
Hugo Shaka b0afb172eb helm: Add CA Pinning Support (#13685)
helm: Add CA Pinning Support
2022-07-26 17:30:21 +00:00
Hugo Shaka 22c75e1ee9 Support dynamic registration in kube-agent helm chart (#13641)
* Support dynamic registration in kube-agent helm chart(#9846)
* Update docs/pages/setup/helm-reference/teleport-kube-agent.mdx
2022-07-25 20:37:46 +00:00
Marco Dinis 5effbd8359 Add Teleport operator
This commit adds the Teleport operator. The operator reconciles
TeleportUsers and TeleportRoles Kubernetes resources with Users and
Roles Teleport resources.
2022-07-25 15:27:10 -04:00
Hugo Shaka 0adb3c16e8 Allow setting public addresses in teleport-cluster chart (#14603)
Allow setting public addresses in `teleport-cluster` chart
2022-07-21 16:49:38 -04:00
Gus Luxton 30404f5630 helm: Remove old teleport charts (#14111) 2022-07-06 20:16:36 +00:00
Roman Tkachenko 683d11d23e Update versions to 11 (#13528) 2022-06-15 23:28:08 +00:00
Gus Luxtonanddaquinoaldo 339bc6f25b feat(helm): expose securityContext as a value (#13016)
The PodSecurityPolicy specifies `MustRunAsNonRoot` but the image runs as root.
`Error: container has runAsNonRoot and image will run as root (pod: "<redacted>", container: teleport).`
We expose the securityContext to allow forcing to run as a non-root user such as 99 (nobody) and respect the psp.

Co-authored-by: daquinoaldo <aldd@bendingspoons.com>
2022-06-08 02:31:51 +00:00
Gus LuxtonandAldo D'Aquino ba3065cc40 docs(helm): remove wrong statement from kube-agent highAvailability (#13014)
Co-authored-by: Aldo D'Aquino <18645793+daquinoaldo@users.noreply.github.com>
2022-06-07 20:10:47 +00:00
Tiago Silva e8388cdb0e Fix liveness probe endpoint (#13208)
* fix liveness probe endpoint

* fix helm unittests
2022-06-07 16:49:29 +00:00
Roman Tkachenkoanddaquinoaldo ea394747bb feat(helm): add priorityClassName and extraLabels to kube-agent (#12559)
* feat(helm): add priorityClassName and extraLabels to kube-agent

Signed-off-by: Roman Tkachenko <roman@goteleport.com>

Co-authored-by: daquinoaldo <aldd@bendingspoons.com>
2022-05-10 22:37:20 +00:00
Gus LuxtonandPierre Lebrun a2ece60402 helm: Buddy merge for #11368 (Enable persistence in custom mode) (#11993)
* feat: Standardize persistence

* helm: Use deprecated standalone.existingClaimName when specified over newer persistence.existingClaimName

* chore: Change pvc comment

* feat: Update chart reference

* Update docs/pages/kubernetes-access/helm/reference/teleport-cluster.mdx

Co-authored-by: Pierre Lebrun <pierreyves.lebrun@rakuten.com>
2022-04-16 00:31:14 +00:00
Gus LuxtonandJohannes Kastl 59e03d42e0 helm: Buddy merge for #11493 (#11693)
* examples/chart/teleport-cluster/templates/deployment.yaml: set strategy to 'Recreate' if chartMode is 'standalone' (fixes #11484)

Signed-off-by: Johannes Kastl <kastl@b1-systems.de>

* examples/chart/teleport-cluster/tests/deployment_test.yaml: add test for strategy in standalone mode

Signed-off-by: Johannes Kastl <kastl@b1-systems.de>

* update examples/chart/teleport-cluster/tests/__snapshot__/deployment_test.yaml.snap after running local tests

Co-authored-by: Johannes Kastl <kastl@b1-systems.de>
2022-04-05 04:09:57 +00:00
Gus Luxton 75e0fcbd67 helm: Add support for mounting existing TLS secrets with optional root CA (#11295) 2022-04-01 17:35:21 -03:00
Gus Luxton f512f27851 Remove references to authentication type 'false' from docs (#11621) 2022-04-01 02:40:16 +00:00
d2a656ef3f helm: Allow probe timeouts to be configurable (buddy merge of #11176) (#11396)
* Allow for probe timeouts to be configurable

When setting up a new Teleport enterprise cluster on GCP,
I noticed that I needed to set the probe timeouts to get the
cluster to be healthy. This seems to be a known issue (https://github.com/kubernetes/kubernetes/issues/89898).

As a "stopgap", I've updated the helm chart to allow for end users
to be able to configure these timeouts.

* Update configuration option name and add documentation

* Update docs/pages/kubernetes-access/helm/reference.mdx

Co-authored-by: Gus Luxton <gus@goteleport.com>

* Add tests for probeTimeoutSeconds

* Add probeTimeoutSeconds to required values

* Add probeTimeoutSeconds to teleport-kube-agent

* Add tests for probeTimeoutSeconds to teleport-kube-agent

* Add probeTimeoutSeconds to teleport-kube-agent reference

Co-authored-by: Hunter Madison <hunter.madison@instana.com>
Co-authored-by: Hunter Madison <hmadison@users.noreply.github.com>
2022-03-25 01:56:22 +00:00
Gus Luxton e5cbd620ce helm: Add support for separate Postgres/Mongo listeners in teleport-cluster chart (#10858)
* helm: Update NOTES.txt for AWS ACM

* Add support for separate Postgres/MongoDB listeners in teleport-cluster chart

* Special case backend listener protocol based on presence of ACM annotation

* Add tests for separate listeners

* Add tests for ACM annotation setting backend protocol

* Don't add AWS annotations when not in AWS mode

* Adds for separatePostgresListener/separateMongoListener

Also adds missing example for setitng proxyListenerMode

* Add continuous backups permission to DynamoDB policy

Fixes #11411
2022-03-24 18:41:08 +00:00
Gus Luxton 4baf68a4f1 helm: Set default second factor to "otp" in values (#11034)
https://github.com/gravitational/teleport/pull/10817 states in the docs that the default for `authenticationSecondFactor.secondfactor` is `otp`, but it didn't actually update the values.yaml file to make this change the default. This PR addresses that mistake and brings the chart in-line with the docs.
2022-03-22 17:04:32 +00:00
Gus Luxton 1b90927193 helm: Adds missing namespaces to ConfigMap (#11032) 2022-03-22 14:33:12 +00:00
Gus Luxton ee5b859593 helm: Refine snapshotting for Deployment/StatefulSet in unit tests (#11279) 2022-03-22 01:29:06 +00:00
3c74adf218 Add Helm unit tests (#11062)
* POC for Helm unit tests

This uses https://github.com/vbehar/helm3-unittest to define
expectations of our helm templates

* Test that enterprise is configured correctly

* Added tests for teleport-cluster

* Added tests for teleport-kube-agent

* Removed tests for teleport chart

* Add tests for teleport-cluster Deployment

* Run shorter tests first

* Fix Docker plugin installation and add update-helm-snapshots target

* Add README

* Fix lint syntax error and add some missing linters

* Add missing ImagePullPolicy to Deployment and StatefulSet

* Add Deployment tests for teleport-kube-agent

* Fix replicaCount logic

* Add clarification to values

* Add StatefulSet suite for teleport-kube-agent

* Update snapshots after merge with master

* Helm tests are quicker than bash tests

* Add tests for extraEnv

* Random space

* Tidy up formatting of multiple tests

* [debug] List helm plugins and directories

* Special case Helm linting when running in CI

* Make trailing line breaks consistent

* Special case Helm linting when running in CI

* Add contribution guidelines for Helm charts

* Add contribution guidelines to READMEs

* Deprecate old charts

* Typo

* Spacing

* Clarification

* Update examples/chart/CONTRIBUTING.md

* Don't erroneously set extraEnv for initContainers

* Rename update-helm-snapshots -> test-helm-update-snapshots for clarity

Co-authored-by: Gus Luxton <gus@goteleport.com>
Co-authored-by: Roman Tkachenko <roman@goteleport.com>
2022-03-20 19:01:58 +00:00
Gus Luxton a463dacaf2 helm: Adds extraArgs and extraEnv to teleport-kube-agent (#11155)
* helm: Adds extraArgs and extraEnv to teleport-kube-agent

These were present in teleport-cluster but not teleport-kube-agent. This PR fixes that.

* Line breaks

* Also add to StatefulSet
2022-03-17 18:22:59 +00:00
Erick ReyesandGus Luxton 508bf7adb2 helm: include static_labels in database example (#10414)
* Updated comment

Update clarifying comment for database section.

* Update examples/chart/teleport-kube-agent/values.yaml

Co-authored-by: Gus Luxton <gus@goteleport.com>
2022-03-17 03:04:35 +00:00
Peter CandGus Luxton 3723b9d472 Fix TLS multiplexing for the kubernetes_service in the teleport-cluster helm chart (#10002)
Co-authored-by: Gus Luxton <gus@goteleport.com>
2022-03-16 20:37:32 +00:00
Gus Luxton 79e05c0508 helm: Set default second factor to 'otp' (#10817) 2022-03-04 01:58:27 +00:00
Peter Collins 5cb4ff9d94 Add webauthn.yaml lint for teleport-cluster helm chart tests 2022-03-02 18:41:50 -08:00
Peter Collins a4bf397ee8 Set rpId as clusterName instead 2022-03-02 18:41:50 -08:00
Peter Collins db3a9c7596 Add support for webauthn in the teleport-cluster helm chart 2022-03-02 18:41:50 -08:00
Gus Luxton eab8fd2dda helm: Fix enabled clause for db_service when using awsDatabases only (#10643)
Some logic was in the wrong place and was erroneously adding both enabled: true and enabled:false when only awsDatabases was enabled.
2022-03-01 20:01:57 +00:00
Gus Luxton aa1d3c6029 helm: Fix indenting on database autodiscovery (#10622)
I had previously assumed that db_service.aws and db_service.databases.aws were the same key; they are not. This PR fixes this error.
2022-02-25 18:13:57 +00:00
Gus Luxton 1d1efaa70f helm: Revert PodSecurityPolicy change (#10563) 2022-02-23 23:10:06 +00:00
Roman Tkachenko 033debf7e4 Bump version to v10-dev (#10510) 2022-02-22 18:01:11 +00:00
Gus Luxton 562f5bd38b helm: Add AWS database auto-discovery to teleport-kube-agent (#10344)
* helm: Add AWS database auto-discovery to teleport-kube-agent

* Update psp v1beta -> v1 to avoid upcoming deprecation

* Address docs feedback
2022-02-18 02:54:02 +00:00
Joel ea810d30d9 Implement Moderated Sessions (#8563)
* Implement Moderated Sessions
2022-02-15 17:02:10 +01:00
Paul SchisaandZac Bergquist c7a807b45c Update teleport-agent readme links (#9963)
* Update teleport-agent readme links

* Update examples/chart/teleport-kube-agent/README.md

sounds good to me

Co-authored-by: Zac Bergquist <zmb3@users.noreply.github.com>

Co-authored-by: Zac Bergquist <zmb3@users.noreply.github.com>
2022-01-26 14:43:30 -05:00
Peter Collins 28f101ae8f Fix docs and config newline outputs 2022-01-20 18:09:03 -08:00
Peter Collins e8ede04b8a Fix inclusion of non-existant gcp-credentials secret and credentialsPath when credentialSecretName is empty 2022-01-20 18:09:03 -08:00
Mohammad AbudayyehandGus Luxton d3dca90b93 fix: removing new line convergance (#9579)
Co-authored-by: Gus Luxton <gus@goteleport.com>
2022-01-17 18:10:02 +00:00
Matthieu ANTOINEandGus Luxton f949493ab0 helm: Allow setting issuer group for certificate in teleport-cluster (#9138)
* Helm chart - teleport-cluster - add issuer group argument for custom issuer groups such as AWS ACM PCA

* Update documentation reference for helm chart and remove trailing whitespace

* Fix --set typo in documentation and add lint values.

* Update docs/pages/kubernetes-access/helm/reference.mdx

* Add commonName field as optional

Co-authored-by: Gus Luxton <gus@goteleport.com>
2022-01-15 02:46:40 +00:00
Gus Luxton 3cc3bcfadf helm: Add logging configuration to teleport-kube-agent chart (#9632)
* [helm] Re-add space after type in service definition (#9503)

The whitespace after `type:` was being trimmed, which was causing a lint error. Not sure how this got through the linter in the first place.

* helm: Adds log configuration to teleport-kube-agent chart

* Remove erroneous value

* Update reference.mdx

Remove shell prompt character
2022-01-15 02:21:13 +00:00