Web App Service (Web+) enables you to build an exclusive environment based on an application configuration template. In the application configuration template, you can customize basic information used by applications, such as the resources, network environment, and program path. This topic describes how to build a deployment environment in the Web+ console based on a Jenkins template.
PrerequisitesActivate related services and authorize roles
Step 1: Download the Jenkins deployment package
Step 2: Create and deploy an application
- Log on to the Web App Service console and select the required region in the upper-left corner of the page.
- In the Basic Information step, configure basic information about the application and click Next.
Parameter Description Tech Stack Type The type of the technology stack. Select a technology stack based on your business needs. In this example, select Java. Application Name The name of the application. In this example, enter Jenkins-demo. Application Description The description of the application. This parameter is optional. Use Free Storage Space If you enable the Use Free Storage Space feature, uploaded deployment packages, collected logs, and diagnostic information in the lifecycle of the application are all stored in the free storage space. This minimizes storage costs. If you require a high level of data privacy, you can disable this feature. After this feature is disabled, all data is stored in your Object Storage Service (OSS) bucket.
- In the Environment Information step, configure information about the deployment environment and deployment package.
After the configuration is complete, click Next.
Parameter Description Tech Stack Version The version of the technology stack. Select a version from the drop-down list. Environment Name The name of the deployment environment. In this example, enter doc-test-env. Environment Description The description of the deployment environment. This parameter is optional. Package Source The source of the deployment package. You can select Upload Local Application or Use Sample Application. In this example, select Upload Local Application and upload the jenkins.war package downloaded in Step 1: Download the Jenkins deployment package. Package Version The version of the deployment package. Web+ provides a default deployment package version. You can change the default deployment package version. Version Description The description of the deployment package version. This parameter is optional.
- In the Configurations step, select Preset Configuration in the Custom field. After you complete the following configuration, click Create with Custom Configuration. In the Actions dialog box, click OK.
- In the architecture diagram of the Environment section, click Host Instance.
- On the Host Instance page, use default settings for parameters such as the selected Elastic Compute Service (ECS) instance specifications.
- Scroll down the Host Instance page to the Logon Credential section. Select Password and specify a password for the root user of the ECS instance.Logon CredentialNotice Remember your password, which is required when you log on to the ECS instance to obtain the initial administrator password of Jenkins.
- In the Finish step, click View environment Logs.
- In the Change Events dialog box, wait until the changes are complete. Close the dialog box to go to the details page of the deployment environment. Then click the URL on the right side of Public Address.
Step 3: Install and configure Jenkins
After the application is created and deployed, you can connect to Jenkins to install and configure Jenkins.
- Wait until the following logon page appears after Jenkins is initialized.
- Log on to the ECS instance with the password for the root user of the ECS instance.
- Run the following command on the ECS instance:
- On the Unlock Jenkins page, enter the command output in the Administrator password field and click Continue.
- Select Install suggested plugins or Select plugins to install as needed. Wait until the plug-ins are installed.Note It may take some time to install the plug-ins.
- On the Create First Admin User page, enter the logon username and password and click Save and Continue.
- On the Instance Configuration page, confirm the Jenkins URL and click Save and Finish.
- On the Jenkins is almost ready! page, click Restart. Jenkins is installed and configured.