The page has been translated by Gen AI.

Add Build/Deploy (Workload Deployment)

The user can, through the following steps, create a new build pipeline in an already created DevOps Console project, build the source to create an image, and perform workload deployment on a Kubernetes cluster.

The workload added via Add Workload will be used in Deploy to K8S Stage Setup.

Build/Deploy Add Getting Started

To begin adding build/deployment, follow these steps.

  1. Click the Project card on the Main page. You will be taken to the Project Dashboard page.

Add code repository (Option)

Info
Proceed only if a new code repository is needed.

To add a code repository, follow these steps.

  1. On the Code Repository page, click the Add Code Repository button in the upper right. You will be taken to the Add Code Repository page.
  2. On the Add Code Repository page, enter and configure each item.
  3. Connection Test Click the button.
  4. Click the Save button.
    ItemExplanation
    Repository typeSelect the repository to use
    • Registered tools: Users can select and use the types of SCM Repository tools (Github, Gitlab, etc.) that are available.
    • Unregistered tools: You can enter the domain of a tool that is not registered. The unregistered tool entry appears only for App templates that do not include source code (Environment Only).
    New/Existing usageSelect Create new repository or Use existing repository
    Repository informationEnter repository information
    • When creating a new repository, the URL is formed from the project group name/project name.
    Authentication informationEnter authentication credentials.
    Repository informationEnter repository information
    • You can use a code repository that is not registered as a tool in DevOps Console.
    • You must also go through the URL check process.
    Table. Code Repository Add Input Items

Add image repository (Option)

Information
Proceed only if a new image repository is needed.

To add an image repository, follow these steps.

App. Add image repository

  1. On the Image Repository page, click the App. Add Image Repository button in the upper right. You will be taken to the App. Add Image Repository page.
  2. App. Add Image Repository page, enter and configure each item.
  3. Connection Test Click the button.
  4. Click the Save button.
    ItemExplanation
    Select repository typeSelect the image repository type.
    To use an image repository not registered in the Devops Console, select the Image Registry type.
    Choose whether to create a repositoryChoose whether to create a new repository or use an existing one.
    • If you selected the Docker hub or Image Registry type earlier, you can only select Use existing repository.
    Registered toolEnter repository information.
    Unregistered toolEnter repository information
    • You can register an image repository that is not registered with the DevOps Console tool.
    • Click the URL Check button to proceed with the verification process.
    • Only Use existing repository can be selected.
    Table. App. Add Image Repository Input Fields

Add pull-only image repository

  1. On the Image Repository page, click the Add Pull-Only Image Repository button in the upper right. You will be taken to the Add Pull-Only Image Repository page.
  2. Add Pull‑only Image Repository On the page, enter and configure each field.
  3. Connection Test Click the button.
  4. Click the Save button.

Add workload

To add a workload, follow the steps below.

  1. On the Main page, click the Project card. You will be taken to the Project Dashboard page.
  2. Click the Build/Deploy > Kubernetes Deploy menu in the left menu. You will be taken to the Kubernetes Deploy page.
  3. On the Kubernetes deployment page, click the Add workload menu. The Add workload popup opens.
  4. Add Workload Enter the information in the popup window and click the Save button.
  5. In the confirmation popup, click the Confirm button to complete adding the workload.
    Item
    Explanation
    Query targetOnly workloads deployed with the same Base image as the App template used when the project was first created are displayed.
    Workload already registered in the projectShows the workload already registered in the project.
    • Workloads already registered in the project cannot be added.
    Table. Additional Workload Input Items

Modify K8S authentication information

K8S credentials are the authentication information used to verify permission to use a K8S cluster/namespace when performing a deployment in the build pipeline.

To modify the K8S credentials, follow these steps.

  1. On the Deployment Details page, click the Edit Credentials icon to the right of K8S Cluster/Namespace. The Edit Credentials popup will open.
  2. Authentication information is fixed to the logged-in user’s account. Click the Save button to edit.
  3. In the confirmation popup, click the Confirm button.
  4. K8S authentication information will be changed to the logged-in user.

Add Build Pipeline

To add a build pipeline, follow these steps.

  1. On the Main page, click the Project card. You will be taken to the Project Dashboard page.
  2. In the left menu, click the Build/Deploy > Build Pipeline menu. You will be taken to the Build Pipeline page.
  3. Build Pipeline page, click the Add Pipeline button at the top right. You will be taken to the Add Pipeline page.
  4. Add Pipeline Enter or configure each field on the page.
  5. Click the Next button.
    ItemExplanation
    CategorySelect Development or Operations
    Jenkins URLSelect Jenkins from the list to add a build pipeline.
    Build AgentSelect the agent (build environment) on which the build pipeline will run.
    Click the Info icon to view the list of tools provided by the agent.
    Build environment OSDisplays the OS information of the environment where the build agent runs.
    Folder typeSelect the folder type.
    • Existing folder: Add a pipeline under an already created folder in Jenkins.
    • New folder: Create a new folder in Jenkins and add a pipeline under it.
    folderSelect a folder from the list or enter the name of a new folder to create.
    Pipeline namePlease enter the pipeline name.
    Parameter settingSet the parameters to be used in the pipeline.
    Environment variable configurationSet the environment variables to be used in the pipeline.
    Stage SettingsConfigure the stage to be used in the pipeline.
    Configure email recipients for build resultsSet the recipients who will receive the result email after the pipeline completes (success/failure).
    Table. Additional Build Pipeline Settings

Setting Parameters

Follow these steps to set the parameters used when running the pipeline.

  1. Click the Parameter card.
  2. Click the Add button to add a parameter.
  3. Click the Apply button to complete the parameter settings.

Setting Environment Variables

Follow these steps to set environment variables for use in the pipeline.

  1. Click the Environment Variable area. The Environment Variable Registration page opens on the right.
  2. A list of pre-registered environment variables appears, and select the checkboxes for the environment variables you want to use.
  3. Check the selected environment variable and click the Apply button to complete the environment variable configuration.

Configure email recipients for build results

To set the recipients who will receive the build results by email, follow these steps.

  1. Click the Mail Recipient area. The Add Mail Recipient page opens on the right.
  2. In the Search area, search for the recipient and add them.
  3. Click the Apply button to complete the mail recipient settings.

Add additional stage

Checkout stage setup

To add a Checkout stage, follow these steps.

  1. Click the New Stage area. The Stage Settings page opens on the right.
  2. On the Stage Settings page, select Checkout as the Stage Type.
  3. After entering the information, click the Apply button. (You can select the code repository you added from 코드 저장소 추가하기 (Option) on the URL.)
    Itemdescription
    URLSelect the code repository to perform the checkout.
    Branch nameEnter the name of the branch to checkout.
    표. Checkout 스테이지 입력 항목

Setting up the Build stage

To add a Build stage, follow these steps.

  1. Click the Add icon to add a new stage.
  2. Click the New Stage area. The Stage Settings page opens on the right.
  3. On the Stage Settings page, select Build as the Stage Type.
  4. After entering information on the Stage Settings page, click the Apply button.
    ItemExplanation
    languageSelect the programming language used by the application.
    Build toolSelect the Build tool used for building the application.
    Provides default Shell commands based on the selected Build tool.
    Shell commandEnter the command to use for building the application.
    All commands available in the Shell can be used.
    Table. Build stage input items

Docker Build Stage Setup

To add a Docker Build stage, follow these steps.

  1. Click the Add icon to add a new stage.
  2. Click the New Stage area. The Stage Settings page opens on the right.
  3. Select Docker Build as the Stage Type.
  4. After entering the information, click the Apply button. (You can select the image repository you added in Registry URL from Add Image Repository (Option).)
item
Explanationexample
Registry URL (docker push)Select the image repository where the Docker build result image will be pushed.
IDThe ID value of the account to be used for the image repository
image tag patternThe Docker image tag is automatically generated according to the selected pattern.
  • {YYYYMMDD}: year, month, and day
  • {HHMMSS}: hour, minute, and second
  • {BUILD_NUM}: the number of the current build pipeline execution
  • {YYYYMMDD}.{HHMMSS}: 20200414.150938
  • {YYYYMMDD}.{BUILD_NUM}: 20220414.13
Add base image repositoryAdd Base Image Repository A popup window opens.
Registry URL (docker pull)Select the image repository for docker pull when the repository providing the Base Image used in the Dockerfile (FROM clause, docker pull) differs from the repository of the Registry URL (docker push).
Image build toolDisplays the image build tool.
Pre-build commandIf there are any commands that need to be run before building a Docker image, write them in shell command format.cp target/*.jar docker/
Image Build folderIf you need to run the Docker image build from a specific folder, select the checkbox and enter the folder path.docker
DockerfileEnter the Dockerfile filename.Dockerfile
Image build optionsEnter it if you need to use additional options with the image build tool.--no-cache
Build commandDisplays the image build command that will actually be executed.
Post-build commandIf there are commands that need to be executed after building a Docker image, write them in Shell command format.rm -rf docker/*.jar
Table. Docker Build Stage Input Items

Deploy to K8S Stage Setup

Deploy to K8S To add a stage, follow the steps below.

  1. Click the + icon to add a new stage.
  2. Click the New Stage area. The Stage Settings page opens on the right.
  3. On the Stage Settings page, select Deploy to K8S as the Stage Type.
  4. On the Stage Settings page, after entering the information, click the Apply button. (If you select a workload in the type, you can select the workload added in 워크로드 추가하기.)
Item
Explanation
typeSelect deployment type
  • Helm release (Helm chart type)
  • Workload
  • ArgoCD
K8S clusterSelect a K8S cluster
  • Helm release (Helm chart type) When selected, a list of Helm releases deployed via the DevOps Console is displayed.
namespacePlease select a namespace.
Helm releaseSelect HelmRelease.
Deployment methodSelect deployment method
  • Recreate
  • Rolling Update
Registry URLSelect the image repository where the image to be deployed to Kubernetes has been docker pushed.
SecretSelect the secret information input method
  • Auto-generate: Automatically create the secret corresponding to the selected image repository from the Registry URL in the DevOps Console and use it.
  • Use existing secret: Use a pre-created secret through K8S secret management.
Table. Deploy to K8S stage input items

Check the final pipeline script

  1. Check the build pipeline script that will actually be generated. If needed, edit the script directly.
  2. Click the Complete button to finish adding the pipeline.

Pipeline addition result

Note
The added pipeline does not run automatically. If execution is required, run the pipeline manually.
Add Build/Deploy (Helm Chart Deployment)
Add Build/Deploy (VM Deployment)