YAML模式
2022世界杯阿根廷预选赛赛程resources:—name:type: HelmChart configuration: sourceArtifactory: artifactoryIntegration repository: chart: version: pin: versionId: version:
标签
的名字
一个字母数字标识资源的字符串(允许使用下划线)。
类型
必须HelmChart
对于此资源类型。
配置
指定资源的所有配置选择。
标签 |
描述 |
必需的/可选 |
---|---|---|
sourceArtifactory |
的名称Artifactory集成 | 要求 |
存储库 |
Artifactory中Helm存储库的名称 | 要求 |
图表 |
舵图的名称 | 要求 |
版本 |
标识Helm图表版本号的字符串 | 要求 |
销 |
此配置可用于将资源固定到特定版本。固定资源版本将被引用此资源作为输入的步骤使用,更新的版本将被忽略。 用户在选择要固定的HelmChart资源版本时有两个配置选项:
或
使用该资源作为输出的步骤仍然可以生成新版本。对于使用该资源作为输入的步骤,新版本将是可见的,只要它们是创建该版本的步骤的同一运行的一部分。 当创建一个新的运行时,手动自定义触发器仍然可以用来覆盖固定的版本到不同的版本。 |
可选 |
环境变量
每当HelmChart
在步骤中使用时,将自动提供一组可在步骤中使用的环境变量。
环境变量 |
描述 |
---|---|
res_ < resource_name > _name |
资源名称 |
res_ < resource_name > _sourceArtifactory |
Artifactory中Helm存储库的名称 |
res_ < resource_name > _chart |
舵图的名称 |
res_ < resource_name > _version |
标识Helm图表版本号的字符串 |
例子
- 这个例子需要一个Artifactory集成而且GitHub集成.
- 本例的管线DSL可在这个存储库在JFrogGitHub帐户。
2022世界杯阿根廷预选赛赛程resources:—name: git_repo type: GitRepo configuration: gitProvider: git_r path: jfrog/charts—name: helm_repo type: HelmChart configuration: sourceArtifactory: art_r repository: helm-local/ chart: test version: 1.0.0 pipelines:—name: test_helm configuration: nodePool: win_2019 steps:—name: helm_pub type: HelmPublish configuration: chartPath: ./simplehelm inputResources:—name: git_repo outputResources:—name: helm_repo # required execution: onStart: - write-output " execution step…"- Get-Variable | format-table onSuccess: - write-output " execution step…"Get-Variable | format-table onFailure: - write-output " execution step…"- Get-Variable | format-table onComplete: #always - write-output " execute step…"- Get-Variable |格式-table