หน้านี้ยังไม่พร้อมใช้งานในภาษาท้องถิ่นของคุณ เรากำลังพยายามอย่างหนักเพื่อเพิ่มเวอร์ชันภาษาอื่น ๆ เพิ่มเติม ขอบคุณสำหรับการสนับสนุนเสมอมา

Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive

Configuring Parameters

Updated on 2025-01-03 GMT+08:00

By default, the codeBranch parameter and predefined parameters are generated for a build task. You can modify the type and value of codeBranch and add custom parameters as required.

Predefined Parameters

The values of predefined parameters are automatically generated by the system and do not need to be defined, as shown in Table 1. You can use ${Parameter name} to reference the parameters in the code.

Table 1 Predefined parameters

Parameter

Description

BUILDNUMBER

Build ID in the format of date.times that this build task is run on that day. For example: 20200312.3.

TIMESTAMP

Build task running timestamp. For example: 20190219191621.

INCREASENUM

Total number of times that the build task is run. The value starts from 1 and is incremented by 1 each time the task is run.

PROJECT_ID

ID of the project where the build task is located.

WORKSPACE

Root directory of the source code pulled by the build task, also known as the workspace.

GIT_TAG

Code tag name. This parameter only has a value if you have specified the downloaded code by tag.

COMMIT_ID_SHORTER

First eight digits of the code commit ID. This parameter only has a value if you have specified the downloaded code by commit ID.

COMMIT_ID

Code commit ID. For example: b6192120acc67074990127864d3fecaf259b20f5.

Adding Custom Parameters

On the page for configuring the build task, click the Parameters tab. On the displayed page, click Create Parameter, and set parameters according to Table 2.

Table 2 Adding custom parameters

Name

Type

Default Value

Private Parameter

Runtime Settings

Params Description

Name of a custom parameter. The value can contain a maximum of 128 characters, including letters, digits, and underscores (_).

NOTE:
  • Do not use the following fields: LD_PRELOAD, LD_LIBRARY_PATH, PATH, BASH_ENV and GIT_SSH_COMMAND.
  • Symbols are not supported.

String

Default value of the custom parameter. Max. 8,192 characters.

Specify whether the parameter is private or not. If the parameter is private, the system encrypts the input parameter for storage and only decrypts the parameter for usage. Private parameters are not displayed in run logs.

Specify whether to set this parameter when running the build task.

If Runtime Settings is enabled, the parameter value can be changed when you click to run the build task, and the system reports the parameter to CodeArts Pipeline.

Enter additional information to describe the parameter. Max. 1,024 characters.

Enumeration

In the displayed dialog box, enter enumerated values in the Value text box. Each parameter value must end with a semicolon (;). Max. 8,192 characters.

Once you have set the enumerated values, select a default value for the parameter from the Default Value drop-down list box.

Auto Increment

Default value of the custom parameter. Max. 8,192 characters.

Using Parameters

The following section describes how to use custom parameters, as shown in Figure 1.

Figure 1 Custom parameters
  1. On the page for configuring the build task, click the Build Actions tab, enter ${myparam} in the Version field of the Upload to Release Repo action, and click Save and Run.
  2. In the displayed dialog box, change the value of myparam to 1.0.1.2 and click Confirm. Wait until the build task is completed.
    Figure 2 Setting the runtime parameters
  3. Go to the release repo and find the resulting build package. The version number is the modified value of myparam.
    Figure 3 Viewing the build package

เราใช้คุกกี้เพื่อปรับปรุงไซต์และประสบการณ์การใช้ของคุณ การเรียกดูเว็บไซต์ของเราต่อแสดงว่าคุณยอมรับนโยบายคุกกี้ของเรา เรียนรู้เพิ่มเติม

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback