- What's New
- Service Overview
- Getting Started
- User Guide
-
Template Reference
- Resource Formation Service
-
Application Orchestration Service
- Template Introduction
-
List of Elements
- Resource Indexes
- AntiDDos.Service
- AOS.Batch
- AOS.Stack
- APIG.API
- APIG.ApiGroup
- APIG.Throttle
- APM.AutoScaler
- APM.Pinpoint
- CCE.Addon.AutoScaler
- CCE.Cluster
- CCE.ConfigMap
- CCE.DaemonSet
- CCE.Deployment
- CCE.HelmRelease
- CCE.Ingress
- CCE.Job
- CCE.NodePool
- CCE.Pod
- CCE.Secret
- CCE.Service
- CCE.StatefulSet
- CCE.Storage.EVS
- CCE.Storage.OBS
- CCE.Storage.SFS
- CCI.ConfigMap
- CCI.Deployment
- CCI.Ingress
- CCI.Job
- CCI.Namespace
- CCI.Secret
- CCI.Service
- CCI.StatefulSet
- CCI.Storage.EVS
- CCI.Storage.SFS
- CDN.Cache
- CDN.Domain
- CDN.Host
- CDN.Https
- CDN.PreheatJob
- CDN.Referer
- CDN.RefreshJob
- CDN.Source
- DBSS.Instance
- DCS.Redis
- DDS.CommunityReplicaSetOrSingle
- DIS.Stream
- ECS.CloudServer
- ECS.ServerGroup
- ECS.KeyPair
- EVS.NonSharedVolume
- EVS.SharedVolume
- FGS.ApigEventMap
- FGS.CtsEventMap
- FGS.DisEventMap
- FGS.DmsEventMap
- FGS.Function
- FGS.LtsEventMap
- FGS.ObsEventMap
- FGS.TimerEventMap
- FGS.SmnEventMap
- HSS.Instance
- IAM.Agency
- IAM.UserGroup
- MRS.Cluster
- NAT.Instance
- NAT.SNatRule
- OBS.Bucket
- RDS.MySQL
- RDS.MySQL.DataBase
- RDS.MySQL.User
- RDS.PostgreSQL
- SCM.Cert
- ServiceStage.Agent
- ServiceStage.AppGroup
- ServiceStage.ContainerComponent
- ServiceStage.Job
- ServiceStage.StatefulApplication
- ServiceStage.StatelessApplication
- SFS.FileSystem
- SMN.Subscription
- SMN.Topic
- ULB.Healthmonitor
- ULB.Listener
- ULB.LoadBalancer
- ULB.Member
- ULB.Pool
- VPCEndpoint.Endpoint
- VPCEndpoint.EndpointService
- VPC.EIP
- VPC.FirewallGroup
- VPC.FirewallPolicy.Egress
- VPC.FirewallPolicy.Ingress
- VPC.FirewallRule
- VPC.SecurityGroup
- VPC.SecurityGroupRule
- VPC.Subnet
- VPC.VIP
- VPC.VPC
- VSS.WebScan
- WAF.service
-
Data Structure
- AOS.BatchItem
- APIG.BackendApi
- APIG.FuncInfo
- APIG.MockInfo
- APM.AutoscalerAction
- APM.AutoscalerActionParameters
- APM.AutoscalerCondition
- APM.AutoscalerRule
- Basic.KeyValuePair
- Basic.Label
- Basic.LabelSelector
- Basic.NameAndSecretValue
- Basic.NameKeyPair
- Basic.NameValuePair
- CCE.Addon.AutoScaler.Node
- CCE.DataVolume
- CCE.HelmChart
- CCE.Labels
- CCE.NodePool
- CCE.PublicIP
- CCI.Network
- CDN.Source
- CDN.CacheRule
- DCS.InstanceBackupPolicy
- DCS.PeriodicalBackupPlan
- DDS.BackupStrategy
- DDS.CommunityReplicaSetOrSingleMode.Flavor
- DDS.DDSCommunity.DataStore
- DDS.DDSCommunityReplicaOrSingle.Flavor
- ECS.DataVolume
- ECS.EIP
- ECS.ExtendParam
- ECS.MountedVolumes
- ECS.NICS
- ECS.Personality
- ECS.PublicIP
- ECS.RootVolume
- ECS.SecurityGroup
- ECS.ServerTags
- ECS.VolumeExtendParam
- EVS.Metadata
- FGS.Environment
- FGS.OBSFilter
- FGS.VpcConfig
- IAM.Agency.Role
- K8S.PodSecurityContext
- K8S.SecurityContext.SeLinuxOptions
- MRS.BootstrapScripts
- MRS.Components
- MRS.TaskNodeGroups
- MRS.Tags
- MySQL.DBUser
- MySQL.DBLinkedUser
- MySQL.DataBase
- MySQL.DataStore
- MySQL.UserDatabase
- PostgreSQL.DataStore
- RDS.BackupStrategy
- RDS.HA
- RDS.HA.Mysql
- RDS.HA.PostgreSQL
- RDS.Volume
- ULB.StickySession
- VPCEndpoint.Ports
- VPC.BandWidth
- VPC.PublicIP
- VSS.Resource
- WAF.Bandwidth
- WAF.Domain
- WAF.Service
- Appendix
-
API Reference
- Before You Start
-
Resource Formation APIs
- Calling APIs
-
Stacks
- Listing Events of a Stack
- Obtaining Stack Metadata
- Listing Stacks
- Creating a Stack
- Obtaining a Stack Template
- Listing Stack Resources
- Listing Stack Outputs
- Continuing to Deploy a Stack
- Deploying a Stack
- Deleting a Stack
- Updating a Stack
- Deleting a Stack with Conditions
- Continuing to Roll Back a Stack
- Execution Plans
- Template Analysis
- Template Management
- Application Orchestration APIs
- Appendix
- FAQs
Show all
concat
During template compilation, the concat function is often used. For example, you may obtain an IP address from the VM result and a listening port number from the APP result, and then print the final and intuitive HTTP access address in the output of the template.
The concat function is a built-in function and used to convert descriptions into strings and concatenate them. It can be embedded with the get_attribute and get_input functions.
In the current version, concat can only be defined in the outputs section. It cannot be defined in the node_templates section or embedded with the get_attribute function.
Syntax
concat: [args, {get_attribute:[...]}, {get_input: [...]} ]
Parameters
Parameter |
Description |
---|---|
args |
Any user-defined field. The value can be an integer, Boolean value, or string. Example: concat: ["string example", 100, -10, true, false], {get_attribute: [...]}, {get_input: [...]} There is no sequence requirement for the preceding three parameters. |
Return Value
Strings that are successfully concatenated are returned.
Examples
properties: package: image: {get_input: magento-image} imagePullPolicy: {get_input: imagePullPolicy} env: - name: MYSQL_HOST # Specifies where MySQL is located. value: concat: - {get_input: mysql-name} - .default.svc.cluster.local # Actual address of MySQL, which is an internal domain name of Kubernetes. - name: MYSQL_USER value: {get_input: mysql-user} - name: MYSQL_PASSWORD value: {get_input: mysql-password} - name: MYSQL_DATABASE value: {get_input: mysql-database} - name: ACCESS_URL value: concat: - "http://" - {get_input: magento-EIP} - ":" - {get_input: magento-EPORT-s}
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.