mirror of
https://github.com/drone-plugins/drone-docker.git
synced 2026-06-13 10:41:32 +08:00
Compare commits
19 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| f6164cf702 | |||
| f946dac9ae | |||
| 801ca62c15 | |||
| 95df76b75d | |||
| d9b3767c94 | |||
| 1482f4d794 | |||
| 19d0d55c04 | |||
| ce792a8072 | |||
| 33ffeb9986 | |||
| 0eaa5cb475 | |||
| 4277ba8a92 | |||
| a95059bc84 | |||
| 3ba3d25d31 | |||
| a6ed4e0fb0 | |||
| c5bbcaaff5 | |||
| b5191aec1c | |||
| 4eeea21716 | |||
| cff5ad3593 | |||
| 3209af48cb |
@@ -398,6 +398,412 @@ pipeline:
|
|||||||
- acr
|
- acr
|
||||||
buildIntelligence:
|
buildIntelligence:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
- stage:
|
||||||
|
name: rf-linux-amd64
|
||||||
|
identifier: rf_linamd64
|
||||||
|
description: ""
|
||||||
|
type: CI
|
||||||
|
spec:
|
||||||
|
cloneCodebase: true
|
||||||
|
caching:
|
||||||
|
enabled: false
|
||||||
|
paths: []
|
||||||
|
platform:
|
||||||
|
os: Linux
|
||||||
|
arch: Amd64
|
||||||
|
runtime:
|
||||||
|
type: Cloud
|
||||||
|
spec: {}
|
||||||
|
execution:
|
||||||
|
steps:
|
||||||
|
- step:
|
||||||
|
type: GitClone
|
||||||
|
name: Clone RF Dockerfiles
|
||||||
|
identifier: clone_rf
|
||||||
|
spec:
|
||||||
|
connectorRef: RapidFortPlugins
|
||||||
|
build:
|
||||||
|
type: branch
|
||||||
|
spec:
|
||||||
|
branch: main
|
||||||
|
cloneDirectory: rf-plugins
|
||||||
|
- step:
|
||||||
|
type: Run
|
||||||
|
name: Build Binary
|
||||||
|
identifier: build_binary
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: golang:1.25.7
|
||||||
|
shell: Sh
|
||||||
|
command: go build -a -tags netgo -o release/linux/amd64/drone-<+matrix.repo> ./cmd/drone-<+matrix.repo>
|
||||||
|
envVariables:
|
||||||
|
CGO_ENABLED: "0"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
|
- step:
|
||||||
|
type: Plugin
|
||||||
|
name: RF Build and Push on Tag
|
||||||
|
identifier: rf_docker_build_push_tag
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: plugins/docker
|
||||||
|
settings:
|
||||||
|
username: <+secrets.getValue("harnesssecureusername")>
|
||||||
|
password: <+secrets.getValue("dockerHarnessSecurePwd")>
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.linux.amd64.rf
|
||||||
|
auto_tag: "true"
|
||||||
|
auto_tag_suffix: linux-amd64
|
||||||
|
base_image_username: <+secrets.getValue("harness0HARUsername")>
|
||||||
|
base_image_password: <+secrets.getValue("harness0HARPAT")>
|
||||||
|
base_image_registry: harness0.harness.io/oci/docker_artifacts
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "tag"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
|
- step:
|
||||||
|
type: BuildAndPushDockerRegistry
|
||||||
|
name: RF Build and Push on Branch
|
||||||
|
identifier: rf_build_push_branch
|
||||||
|
spec:
|
||||||
|
connectorRef: harnesssecure
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
tags:
|
||||||
|
- linux-amd64
|
||||||
|
caching: false
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.linux.amd64.rf
|
||||||
|
envVariables:
|
||||||
|
PLUGIN_BASE_IMAGE_USERNAME: <+secrets.getValue("harness0HARUsername")>
|
||||||
|
PLUGIN_BASE_IMAGE_PASSWORD: <+secrets.getValue("harness0HARPAT")>
|
||||||
|
PLUGIN_BASE_IMAGE_REGISTRY: harness0.harness.io/oci/docker_artifacts
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "branch"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
|
variables:
|
||||||
|
- name: CI_ENABLE_BARE_METAL
|
||||||
|
type: String
|
||||||
|
description: ""
|
||||||
|
required: false
|
||||||
|
value: "false"
|
||||||
|
- stage:
|
||||||
|
name: rf-linux-arm64
|
||||||
|
identifier: rf_linarm64
|
||||||
|
description: ""
|
||||||
|
type: CI
|
||||||
|
spec:
|
||||||
|
cloneCodebase: true
|
||||||
|
caching:
|
||||||
|
enabled: false
|
||||||
|
paths: []
|
||||||
|
platform:
|
||||||
|
os: Linux
|
||||||
|
arch: Arm64
|
||||||
|
runtime:
|
||||||
|
type: Cloud
|
||||||
|
spec: {}
|
||||||
|
execution:
|
||||||
|
steps:
|
||||||
|
- step:
|
||||||
|
type: GitClone
|
||||||
|
name: Clone RF Dockerfiles
|
||||||
|
identifier: clone_rf
|
||||||
|
spec:
|
||||||
|
connectorRef: RapidFortPlugins
|
||||||
|
build:
|
||||||
|
type: branch
|
||||||
|
spec:
|
||||||
|
branch: main
|
||||||
|
cloneDirectory: rf-plugins
|
||||||
|
- step:
|
||||||
|
type: Run
|
||||||
|
name: Build Binary
|
||||||
|
identifier: build_binary
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: golang:1.25.7
|
||||||
|
shell: Sh
|
||||||
|
command: go build -a -tags netgo -o release/linux/arm64/drone-<+matrix.repo> ./cmd/drone-<+matrix.repo>
|
||||||
|
envVariables:
|
||||||
|
CGO_ENABLED: "0"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
|
- step:
|
||||||
|
type: Plugin
|
||||||
|
name: RF Build and Push on Tag
|
||||||
|
identifier: rf_docker_build_push_tag
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: plugins/docker
|
||||||
|
settings:
|
||||||
|
username: <+secrets.getValue("harnesssecureusername")>
|
||||||
|
password: <+secrets.getValue("dockerHarnessSecurePwd")>
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.linux.arm64.rf
|
||||||
|
auto_tag: "true"
|
||||||
|
auto_tag_suffix: linux-arm64
|
||||||
|
base_image_username: <+secrets.getValue("harness0HARUsername")>
|
||||||
|
base_image_password: <+secrets.getValue("harness0HARPAT")>
|
||||||
|
base_image_registry: harness0.harness.io/oci/docker_artifacts
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "tag"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
|
- step:
|
||||||
|
type: BuildAndPushDockerRegistry
|
||||||
|
name: RF Build and Push on Branch
|
||||||
|
identifier: rf_build_push_branch
|
||||||
|
spec:
|
||||||
|
connectorRef: harnesssecure
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
tags:
|
||||||
|
- linux-arm64
|
||||||
|
caching: false
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.linux.arm64.rf
|
||||||
|
envVariables:
|
||||||
|
PLUGIN_BASE_IMAGE_USERNAME: <+secrets.getValue("harness0HARUsername")>
|
||||||
|
PLUGIN_BASE_IMAGE_PASSWORD: <+secrets.getValue("harness0HARPAT")>
|
||||||
|
PLUGIN_BASE_IMAGE_REGISTRY: harness0.harness.io/oci/docker_artifacts
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "branch"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
|
variables:
|
||||||
|
- name: CI_ENABLE_BARE_METAL
|
||||||
|
type: String
|
||||||
|
description: ""
|
||||||
|
required: false
|
||||||
|
value: "false"
|
||||||
|
- stage:
|
||||||
|
name: win-1809-amd64-rf
|
||||||
|
identifier: win1809amd64rf
|
||||||
|
description: ""
|
||||||
|
type: CI
|
||||||
|
spec:
|
||||||
|
cloneCodebase: true
|
||||||
|
caching:
|
||||||
|
enabled: true
|
||||||
|
infrastructure:
|
||||||
|
type: VM
|
||||||
|
spec:
|
||||||
|
type: Pool
|
||||||
|
spec:
|
||||||
|
poolName: windows-2019
|
||||||
|
os: Windows
|
||||||
|
execution:
|
||||||
|
steps:
|
||||||
|
- step:
|
||||||
|
type: GitClone
|
||||||
|
name: Clone RF Dockerfiles
|
||||||
|
identifier: Clone_RF_Dockerfiles
|
||||||
|
spec:
|
||||||
|
connectorRef: RapidFortPlugins
|
||||||
|
cloneDirectory: rf-plugins
|
||||||
|
build:
|
||||||
|
type: branch
|
||||||
|
spec:
|
||||||
|
branch: main
|
||||||
|
- step:
|
||||||
|
type: Run
|
||||||
|
name: Build Binary
|
||||||
|
identifier: go_build
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: golang:1.23.0
|
||||||
|
shell: Sh
|
||||||
|
command: |-
|
||||||
|
# disable cgo
|
||||||
|
export CGO_ENABLED=0
|
||||||
|
|
||||||
|
go build -o release/windows/amd64/drone-<+matrix.repo>.exe ./cmd/drone-<+matrix.repo>
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- gcr
|
||||||
|
- gar
|
||||||
|
- ecr
|
||||||
|
- acr
|
||||||
|
- step:
|
||||||
|
type: Plugin
|
||||||
|
name: RF Build and Push on Tag
|
||||||
|
identifier: RF_Build_and_Push_on_Tag
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: plugins/docker
|
||||||
|
settings:
|
||||||
|
username: <+secrets.getValue("harnesssecureusername")>
|
||||||
|
password: <+secrets.getValue("dockerHarnessSecurePwd")>
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.windows.amd64.1809.rf
|
||||||
|
auto_tag: "true"
|
||||||
|
auto_tag_suffix: windows-1809-amd64
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "branch"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- gar
|
||||||
|
- ecr
|
||||||
|
- acr
|
||||||
|
- step:
|
||||||
|
type: BuildAndPushDockerRegistry
|
||||||
|
name: RF Build and Push on Branch
|
||||||
|
identifier: rf_build_push_branch
|
||||||
|
spec:
|
||||||
|
connectorRef: harnesssecure
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
tags:
|
||||||
|
- windows-1809-amd64
|
||||||
|
caching: false
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.windows.amd64.1809.rf
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "branch"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- gar
|
||||||
|
- ecr
|
||||||
|
- acr
|
||||||
|
delegateSelectors:
|
||||||
|
- windows-vm
|
||||||
|
- stage:
|
||||||
|
name: win-ltsc2022-amd64-rf
|
||||||
|
identifier: winamd64rf
|
||||||
|
description: ""
|
||||||
|
type: CI
|
||||||
|
spec:
|
||||||
|
cloneCodebase: true
|
||||||
|
caching:
|
||||||
|
enabled: false
|
||||||
|
paths: []
|
||||||
|
platform:
|
||||||
|
os: Windows
|
||||||
|
arch: Amd64
|
||||||
|
runtime:
|
||||||
|
type: Cloud
|
||||||
|
spec: {}
|
||||||
|
execution:
|
||||||
|
steps:
|
||||||
|
- step:
|
||||||
|
type: GitClone
|
||||||
|
name: Clone RF Dockerfiles
|
||||||
|
identifier: Clone_RF_Dockerfiles
|
||||||
|
spec:
|
||||||
|
connectorRef: RapidFortPlugins
|
||||||
|
cloneDirectory: rf-plugins
|
||||||
|
build:
|
||||||
|
type: branch
|
||||||
|
spec:
|
||||||
|
branch: main
|
||||||
|
- step:
|
||||||
|
type: Run
|
||||||
|
name: Build Binary -ltsc2022
|
||||||
|
identifier: build_amd64ltsc2022
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: golang:1.23.0
|
||||||
|
shell: Sh
|
||||||
|
command: |-
|
||||||
|
# disable cgo
|
||||||
|
export CGO_ENABLED=0
|
||||||
|
|
||||||
|
go build -o release/windows/amd64/drone-<+matrix.repo>.exe ./cmd/drone-<+matrix.repo>
|
||||||
|
envVariables:
|
||||||
|
CGO_ENABLED: "0"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- gcr
|
||||||
|
- gar
|
||||||
|
- ecr
|
||||||
|
- acr
|
||||||
|
- step:
|
||||||
|
type: Plugin
|
||||||
|
name: RF Build and Push on Tag
|
||||||
|
identifier: RF_Build_and_Push_on_Tag
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: plugins/docker
|
||||||
|
settings:
|
||||||
|
username: <+secrets.getValue("harnesssecureusername")>
|
||||||
|
password: <+secrets.getValue("dockerHarnessSecurePwd")>
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.windows.amd64.ltsc2022.rf
|
||||||
|
auto_tag: "true"
|
||||||
|
auto_tag_suffix: windows-ltsc2022-amd64
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "tag"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- gar
|
||||||
|
- ecr
|
||||||
|
- acr
|
||||||
|
- step:
|
||||||
|
type: BuildAndPushDockerRegistry
|
||||||
|
name: RF Build and Push on Branch
|
||||||
|
identifier: rf_build_push_branch
|
||||||
|
spec:
|
||||||
|
connectorRef: harnesssecure
|
||||||
|
repo: harnesssecure/<+matrix.repo>
|
||||||
|
tags:
|
||||||
|
- windows-ltsc2022-amd64
|
||||||
|
caching: false
|
||||||
|
dockerfile: rf-plugins/drone-docker/docker/<+matrix.repo>/Dockerfile.windows.amd64.ltsc2022.rf
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "branch"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- gar
|
||||||
|
- ecr
|
||||||
|
- acr
|
||||||
|
buildIntelligence:
|
||||||
|
enabled: false
|
||||||
- stage:
|
- stage:
|
||||||
name: Manifest and Release
|
name: Manifest and Release
|
||||||
identifier: Manifest
|
identifier: Manifest
|
||||||
@@ -410,6 +816,18 @@ pipeline:
|
|||||||
paths: []
|
paths: []
|
||||||
execution:
|
execution:
|
||||||
steps:
|
steps:
|
||||||
|
- step:
|
||||||
|
type: GitClone
|
||||||
|
name: Clone RF Manifest Templates
|
||||||
|
identifier: clone_rf_manifest
|
||||||
|
spec:
|
||||||
|
connectorRef: RapidFortPlugins
|
||||||
|
build:
|
||||||
|
type: branch
|
||||||
|
spec:
|
||||||
|
branch: main
|
||||||
|
cloneDirectory: rf-plugins
|
||||||
|
contextType: Pipeline
|
||||||
- step:
|
- step:
|
||||||
type: Plugin
|
type: Plugin
|
||||||
name: Manifest
|
name: Manifest
|
||||||
@@ -435,6 +853,29 @@ pipeline:
|
|||||||
- ecr
|
- ecr
|
||||||
- heroku
|
- heroku
|
||||||
- acr
|
- acr
|
||||||
|
- step:
|
||||||
|
type: Plugin
|
||||||
|
name: RF Manifest
|
||||||
|
identifier: rf_manifest
|
||||||
|
spec:
|
||||||
|
connectorRef: Plugins_Docker_Hub_Connector
|
||||||
|
image: plugins/manifest
|
||||||
|
settings:
|
||||||
|
username: <+secrets.getValue("harnesssecureusername")>
|
||||||
|
password: <+secrets.getValue("dockerHarnessSecurePwd")>
|
||||||
|
auto_tag: "true"
|
||||||
|
ignore_missing: "true"
|
||||||
|
spec: rf-plugins/drone-docker/docker/<+matrix.repo>/manifest.tmpl
|
||||||
|
when:
|
||||||
|
stageStatus: Success
|
||||||
|
condition: <+codebase.build.type> == "tag"
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
repo:
|
||||||
|
- docker
|
||||||
|
- acr
|
||||||
|
- ecr
|
||||||
|
- gar
|
||||||
platform:
|
platform:
|
||||||
os: Linux
|
os: Linux
|
||||||
arch: Amd64
|
arch: Amd64
|
||||||
|
|||||||
Reference in New Issue
Block a user