Skip to content

Jenkins Dashboard

Important

Check out the Must Read section for managing network, compute and oci firewall resources.


Jenkins-Arch


Jenkins-Dashboard

  1. setupoci Pipeline

  2. terraform_files Folder

  3. Region based Views (including Global directory)

1. setupoci Pipeline

This is equivalent to running setupoci.py from CLI. This will generate the .auto.tfvars files based on the CD3 Excel sheet input for the services chosen and commit them to OCI Devops GIT repo. Additionally, it also triggers apply pipelines for the corresponding services chosen in setupoci pipeline.

Below table shows the stages executed in this pipeline along with their description:

setupoci Pipeline Stages

Stage Name Description Possible Outcomes
Validate Input Parameters Validates input file name/size, selected parameters Displays Unstable if any of the
validation fails. Pipeline stops
further execution in that case.
Update setupoci.properties Updates <prefix>_setupoci.properties
with input filename and workflow_type
Displays Failed if any issue during execution
Execute setupoci Executes python code to generate required
tfvars files. The console output for this
stage is similar to setupoci.py execution via CLI.
Multiple options selected will
be processed sequentially in this stage. The Excel sheet can be downloaded from Build artifacts of the setupoci pipeline.
Displays Failed if any issue occurs
during its execution. Further stages
are skipped in that case.
Run Import Commands Based on the workflow_type as 'Export Existing Resources from OCI',
this stage invokes execution of
import_commands_<resource>.sh
shell scripts which will import the
exported objects into tfstate. import_commands for
multiple options selected will be
processed sequentially in this stage.
This stage is skipped for 'Create New Resources in OCI' workflow
Displays Failed if any issue occurs during its execution.
Further stages are skipped in that case.
Git Commit to develop Commits the terraform_files folder to OCI DevOps GIT Repo develop branch.
This will trigger respective terraform pipelines
Pipeline stops further execution if there is nothing to commit. In some cases when tfvars was generated in previous execution,
navigate to apply pipeline and trigger that manually
Trigger Pipelines Corresponding terraform/tofu apply pipelines
are auto triggered based on the service chosen

a. Download CD3 Excel File

Click here for the steps to download excel file after successful completion of 'Execute setupoci' stage of the pipeline. The Excel file is available as an artifact for each build of the setupoci pipeline.

Note: For create_resources (Greenfield workflow), this will be the same Excel file which was uploaded to create resources in OCI. For export_resoucres (Non-Greenfield workflow), this will be the updated Excel file with exported OCI resource data.

2. terraform_files Folder

This is equivalent to /cd3user/tenancies/<prefix>/terraform_files folder on your local system. The region directories along with all service directories, are present under this terraform_files folder. The toolkit will generate the .tfvars files for all resources under the service directory. Inside each service directory, pipelines for terraform/tofu apply and destroy are present.

The pipelines are either triggered automatically from setupoci pipeline or they can be triggered manually by navigating to any service directory path.

apply Pipeline Stages

Stage Name Description Possible Outcomes
Checkout SCM Checks out the latest terraform_files
folder from DevOps GIT repo develop branch
Set Environment Variables Sets the environment variables for region and service name
Plan Runs plan against the
checked out code and saves it in tfplan.out
Pipeline stops further execution if the plan shows no changes.
Displays Failed if any issue while executing the plan
OPA Runs the above generated plan against
Open Policies and displays the violations if any
Displays Unstable if any OPA rule is violated
Get Approval Approval Stage for reviewing the plan.
There is 24 hours timeout for this stage.
Proceed - goes ahead with Apply stage.
Abort - pipeline is aborted and stops further execution
Apply Applies the terraform/tofu configurations Displays Failed if any issue
while executing apply
Git Commit to main Commit to main branch Stage is skipped if any issue while executing apply

destroy Pipeline Stages

Stage Name Description Possible Outcomes
Checkout SCM Checks out the latest terraform_files
folder from DevOps GIT repo develop branch
Set Environment Variables Sets the environment variables for region and service name
Plan Runs terraform plan -destroy or
tofu plan -destroy against the checked out code
Displays Failed if any issue in plan output
Get Approval Approval Stage for reviewing the plan.
There is 24 hours timeout for this stage.
Proceed - goes ahead with Destroy stage.
Abort - pipeline is aborted and stops furter execution
Destroy Destroys the terraform/tofu configurations Displays Failed if any issue
while executing destroy
Git Commit to main Removes tfvars from respective directory in main branch of repo Stage is skipped if any issue while executing apply

3. Region Based Views

Clicking on any of the views displays all apply and destroy pipelines in a single screen. This can also be used to trigger the terraform/tofu pipelines. This also includes Global view for global services like RPC.