Skip to content

image

image value in Kubedeploy controls the main container image settings.

If left unchanged these are the default values that Kubedeploy will work with:

Default image configuration
image:
  repository: nginx # (1)
  pullPolicy: IfNotPresent # (2)
  tag: "latest" # (3)
  command: [] # (4)
  args: [] # (5)
  lifecycle: {} # (6)
  terminationGracePeriodSeconds: 30 # (7)
  1. Defines container repository
  2. Default container pull policy
  3. Defines container image tag
  4. Defines container custom command. Reference
  5. Define container custom arguments. Reference
  6. (Feature state: 1.0.0) Define container custom lifecycle hooks. More info
  7. Define Pod terminationGracePeriodSeconds.

If we wish to deploy different webserver we can do this by simply changing the image repository.

Apache webserver

values.yaml
1
2
3
4
5
6
image:
  repository: httpd
  tag: 2.4
  pullPolicy: Always

replicaCount: 3
Deploy command
helm install webserver sysbee/kubedeploy -f values.yaml

Configurable container lifecycle

Main container is intended to run main application inside a Pod. You can augment it with additionalContainers and initContainers. Only main container supports defining custom lifecycle hooks. See the related documentation from Best practices on use cases.

See also: