woodpecker

by genofire

Helm chartv3.7.8App 3.21.0

A Helm chart for Woodpecker CI

About this chart

woodpecker

Source Code: https://github.com/woodpecker-ci/woodpecker

Installation

To install the latest release of the chart:

# since > 1.6.1
helm install woodpecker oci://ghcr.io/woodpecker-ci/helm/woodpecker --version <VERSION>

# deprecated (but still functional)
helm repo add woodpecker https://woodpecker-ci.org/
helm install woodpecker woodpecker/woodpecker

Note: The woodpecker/woodpecker chart contains both the server and the agent. If you want to install only the server or agent you can use the woodpecker/server or woodpecker/agent charts respectively.

Backend Configuration

The Kubernetes backend configuration is documented in greater detail in the Woodpecker documentation.

Terraform

If you're using the helm-release terraform module, the following definition can be used:

resource "helm_release" "woodpecker" {
  name             = "woodpecker"
  chart            = "woodpecker"
  repository       = "https://woodpecker-ci.org/"
  create_namespace = true # optional
  version          = 3.7.7
  namespace        = "woodpecker"
  count            = 1 # optional
  timeout          = 90 # optional

Upgrading

See the 3.0.0 release notes.

  • split metrics.enabled and the PodMonitor deployment to prometheus.podmonitor.enabled
  • move metrics.interval to prometheus.podmonitor.interval

Requirements

RepositoryNameVersion
agent2.0.1
server3.0.1

Values

KeyTypeDefaultDescription
additionalObjectslist[]Allow adding additional custom kubernets objects
agent.affinityobject{}Specifies the affinity
agent.dnsConfigobject{}Overrides the default DNS configuration
agent.enabledbooltrueEnable the agent component
agent.env.WOODPECKER_BACKENDstring"kubernetes"
agent.env.WOODPECKER_BACKEND_K8S_NAMESPACEstring"woodpecker"
agent.env.WOODPECKER_BACKEND_K8S_NAMESPACE_PER_ORGANIZATIONboolfalse
agent.env.WOODPECKER_BACKEND_K8S_POD_ANNOTATIONSstring""
agent.env.WOODPECKER_BACKEND_K8S_POD_LABELSstring""
agent.env.WOODPECKER_BACKEND_K8S_STORAGE_CLASSstring""
agent.env.WOODPECKER_BACKEND_K8S_STORAGE_RWXbooltrue
agent.env.WOODPECKER_BACKEND_K8S_VOLUME_SIZEstring"10G"
agent.env.WOODPECKER_CONNECT_RETRY_COUNTstring"1"
agent.env.WOODPECKER_SERVERstring"woodpecker-server:9000"
agent.extraSecretNamesForEnvFromlist[]Add extra secret that is contains environment variables
agent.extraVolumeMountslist[]Additional volumes that will be attached to the agent container
agent.extraVolumeslist[]Additional volumes that can be mounted in containers
agent.fullnameOverridestring""Overrides the full name of the chart of the agent component

Deploy woodpecker with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has woodpecker 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 chartwoodpecker is pinned at v3.7.8 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