devtron-operator

by Devtron

Helm chartv0.23.4App 2.2.1

Chart to configure and install Devtron. Devtron is a Kubernetes Orchestration system.

About this chart

Devtron Installation

Devtron is an open source software delivery workflow for Kubernetes written in Go language. It is designed as a self-serve platform for operationalizing and maintaining applications (AppOps) on Kubernetes in a developer friendly way.

Introduction

This chart bootstraps deployment of all required components for installation of Devtron Platform on a Kubernetes cluster using the Helm package manager.

It packages third party components like

How to use it

Install with Helm (Stable)

Follow the given steps to install devtron stable release on your kubernetes cluster

helm repo add devtron https://helm.devtron.ai 

helm install devtron devtron/devtron-operator \
--create-namespace --namespace devtroncd \
--set installer.modules={cicd}

Install with Helm (Beta)

We also release beta versions of devtron every few days before the stable release for people who would like to explore and test beta features before everyone else. If you want to install a fresh devtron from beta release channel, use the chart in our official devtron repository.

This chart is currently not available on the official helm repository therefore you need to download it to install it.

$ git clone [https://github.com/devtron-labs/devtron.git](https://github.com/devtron-labs/devtron.git)
$ cd devtron/charts/devtron
$ helm dependency up
$ #modify values in values.yaml
$ helm install devtron . --create-namespace --namespace devtroncd -f values.yaml

To upgrade your existing devtron installation to beta, use helm upgrade.

$ git clone [https://github.com/devtron-labs/devtron.git](https://github.com/devtron-labs/devtron.git)
$ cd devtron/charts/devtron
$ helm dependency up
$ #modify values in values.yaml
$ helm upgrade devtron . --reuse-values --namespace devtroncd -f devtron-bom.yaml

For more details about configuration see the helm chart configuration

Link to more installation options for Devtron.

Note: There is no option to upgrade to beta on stack manager UI as of now and you may always see upgrade available for latest stable version using which you'll be moved to latest stable version available.

Access Devtron dashboard

Devtron dashboard in now available at the BASE_URL/dashboard, where BASE_URL is same as provided in values.yaml in case of installation via Helm chart.

Check your current devtron version

If you want to check the current version of Devtron you are using, please use the following command.

kubectl -n devtroncd get installers installer-devtron -o jsonpath='{.status.sync.data}' | grep "^LTAG=" | cut -d"=" -f2-

For Devtron version v0.6.0 and higher

Use username:admin and for password run command mentioned below.

kubectl -n devtroncd get secret devtron-secret -o jsonpath='{.data.ADMIN_PASSWORD}' | base64 -d

For Devtron version less than v0.6.0

Use username:admin and for password run command mentioned below.

kubectl -n devtroncd get secret devtron-secret -o jsonpath='{.data.ACD_PASSWORD}' | base64 -d

Configuration

All parameters mentioned in the values.yaml are mandatory.

First section is secrets.env and it has following properties

ParameterDescriptionDefault
POSTGRESQL_PASSWORD*password for postgres database (required)change-me
GIT_TOKENgit token for the gitops work flow, please note this is not for source code of repo and this token should have full access to create, delete, update repository (required)
WEBHOOK_TOKENIf you want to continue using jenkins for CI then please provide this for authentication of requests (optional)

Second section is configs and has following properties

ParameterDescriptionDefault
BASE_URL_SCHEMEeither of http or httpshttp
BASE_URLurl without scheme and trailing slash (required) eg. devtron.aichange-me
DEX_CONFIGdex config if you want to integrate login with SSO (optional) for more information check Argocd documentation
GIT_PROVIDERgit provider for storing config files for gitops, currently only GITHUB and GITLAB are supportedGITHUB
GITLAB_NAMESPACE_IDif GIT_PROVIDER is GITLAB
GITLAB_NAMESPACE_NAMEif GIT_PROVIDER is GITLAB
GIT_USERNAMEgit username for the GIT_PROVIDER
GITHUB_ORGANIZATIONif GIT_PROVIDER is GITHUB
DEFAULT_CD_LOGS_BUCKET_REGIONAWS region of bucket to store CD logs
DEFAULT_CACHE_BUCKETAWS bucket to store docker cache
DEFAULT_CACHE_BUCKET_REGIONAWS region of cache bucket defined in previous step
DEFAULT_BUILD_LOGS_BUCKETAWS bucket to store build logs
CHARTMUSEUM_STORAGE_AMAZON_BUCKETAWS bucket to store charts
CHARTMUSEUM_STORAGE_AMAZON_REGIONAWS region for bucket defined in previous step to store charts
EXTERNAL_SECRET_AMAZON_REGIONAWS region for secret manager to pick
PROMETHEUS_URLurl of prometheus where all cluster data is stored, if this is wrong, you will not be able to see application metrics like cpu, ram, http status code, latency and throughput

example of DEX_CONFIG is

DEX_CONFIG: |-
  connectors:
    - type: oidc
      id: google
      name: Google
      config:
        issuer: https://accounts.google.com
        clientID: xxxxxxxx-qwwdsdsqsxxxxxxxxx.apps.googleusercontent.com
        clientSecret: fssdsdw121wwxssd
        redirectURI: <BASE_URL_SCHEME>://<BASE_URL>/api/dex/callback
        hostedDomains:
        - abc.com

Please Note: Ensure that the cluster has access to the DEFAULT_CACHE_BUCKET, DEFAULT_BUILD_LOGS_BUCKET, CHARTMUSEUM_STORAGE_AMAZON_BUCKET and AWS secrets backends (SSM & secrets manager)

Deploy devtron-operator with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has devtron-operator on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartdevtron-operator is pinned at v0.23.4 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply