Skip to content

Provision Upstream k8s

Overview

This is an example of a Jenkins based pipeline programmatically interacting with the Controller to provision upstream Kubernetes Clusters on Amazon AWS.


Assumptions

  • You have configured credentials in Jenkins so that the pipeline can access the Controller. An illustrative example is shown below.

Jenkins Credentials


Example Pipeline

Step 1: Create Jenkins Item

Create a new Jenkins "Item", provide a name and select "pipeline" for type. Illustrative screenshot below.

Create New Item


Step 2: Cluster Spec Parameter

Select the "This project is parameterized" option and enter "CLUSTER_METADATA". This will carry the Cluster Specs.

Enable Parameter


Step 3: Pipeline

Copy the example Jenkins pipeline from the public Git repo and customize it with your details.


Step 4: Build With Parameters

  • To execute the pipeline, click on "build with parameters"
  • Provide the cluster spec in the parameters
  • Click on build

Build with Parameters