Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(containers): [agent6] Updates on container deploy #32730

Merged
merged 2 commits into from
Jan 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions .gitlab/deploy_containers/conditions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,37 +11,37 @@
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/ && $FORCE_MANUAL != "true"
when: on_success
variables:
AGENT_REPOSITORY: agent-dev
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
IMG_REGISTRIES: dev
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/ && $FORCE_MANUAL == "true"
when: manual
allow_failure: true
variables:
AGENT_REPOSITORY: agent-dev
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
IMG_REGISTRIES: dev
- when: manual
allow_failure: true
variables:
AGENT_REPOSITORY: agent-dev
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
IMG_REGISTRIES: dev

# Rule for job that are triggered on_success on RC pipelines
.on_rc:
- if: $FORCE_MANUAL == "true" && $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/
when: manual
variables:
AGENT_REPOSITORY: agent-dev
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
IMG_REGISTRIES: dev
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/
when: on_success
variables:
AGENT_REPOSITORY: agent-dev
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
IMG_REGISTRIES: dev

# Rule for job that can be triggered manually on final build, deploy to prod repository on stable branch deploy, else to dev repository
.on_final:
Expand Down
23 changes: 4 additions & 19 deletions .gitlab/deploy_containers/deploy_containers_a6.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,8 @@ include:
before_script:
- source /root/.bashrc
- if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version 6 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-6${JMX}-amd64,${IMG_BASE_SRC}-6${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-6${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-6${JMX}-winltsc2022${FLAVOR}-amd64"
- if [[ "$FLAVOR" == "-linux" ]]; then export IMG_SOURCES="${IMG_LINUX_SOURCES}"; elif [[ "$FLAVOR" == "-servercore" ]]; then export IMG_SOURCES="${IMG_WINDOWS_SOURCES}"; else export IMG_SOURCES="${IMG_LINUX_SOURCES},${IMG_WINDOWS_SOURCES}"; fi
- export IMG_DESTINATIONS="${AGENT_REPOSITORY}:${VERSION}${FLAVOR}${JMX}"
- export IMG_SOURCES="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6${JMX}-amd64,${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6${JMX}-arm64"
- export IMG_DESTINATIONS="${AGENT_REPOSITORY}:${VERSION}${JMX}"


.deploy_containers-a6_external:
Expand All @@ -37,10 +34,6 @@ include:
- JMX:
- ""
- "-jmx"
FLAVOR:
- ""
- "-servercore"
- "-linux"


deploy_containers-a6:
Expand Down Expand Up @@ -68,15 +61,7 @@ deploy_containers_latest-a6:
dependencies: []
parallel:
matrix:
- IMG_VARIABLES: "BASE=${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6"
IMG_SOURCES: "%BASE%-amd64,%BASE%-arm64,%BASE%-win1809-amd64,%BASE%-winltsc2022-amd64"
- IMG_SOURCES: ${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6-amd64,${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6-arm64
IMG_DESTINATIONS: ${AGENT_REPOSITORY}:6,${AGENT_REPOSITORY}:latest-py2
- IMG_VARIABLES: "BASE=${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6-jmx"
IMG_SOURCES: "%BASE%-amd64,%BASE%-arm64,%BASE%-win1809-amd64,%BASE%-winltsc2022-amd64"
- IMG_SOURCES: ${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6-jmx-amd64,${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6-jmx-arm64
IMG_DESTINATIONS: ${AGENT_REPOSITORY}:6-jmx,${AGENT_REPOSITORY}:latest-py2-jmx
- IMG_VARIABLES: "BASE=${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6"
IMG_SOURCES: "%BASE%-win1809-servercore-amd64,%BASE%-winltsc2022-servercore-amd64"
IMG_DESTINATIONS: ${AGENT_REPOSITORY}:6-servercore,${AGENT_REPOSITORY}:latest-py2-servercore
- IMG_VARIABLES: "BASE=${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-6-jmx"
IMG_SOURCES: "%BASE%-win1809-servercore-amd64,%BASE%-winltsc2022-servercore-amd64"
IMG_DESTINATIONS: ${AGENT_REPOSITORY}:6-servercore-jmx,${AGENT_REPOSITORY}:latest-py2-servercore-jmx
Loading