-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
feat(gitlab): Job retry on agent.version
and pipeline.changelog
#29546
Conversation
@@ -185,7 +185,7 @@ deploy_staging_iot_agent: | |||
needs: ["build_iot_agent-binary_x64"] | |||
script: | |||
- $S3_CP_CMD $S3_ARTIFACTS_URI/iot/agent ./agent |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here the script can fail on that line. I did the modification below for consistency and will do a follow-up PR for such calls
Gitlab CI Configuration Changes
|
Removed | Modified | Added | Renamed |
---|---|---|---|
0 | 40 | 0 | 0 |
Updated: .gitlab/deploy_containers/deploy_containers_a7.yml
Modified Jobs
.deploy_containers-a7-base
.deploy_containers-a7-base:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-7${JMX}-amd64,${IMG_BASE_SRC}-7${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-7${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-7${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}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
.deploy_containers-a7_external
.deploy_containers-a7_external:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-7${JMX}-amd64,${IMG_BASE_SRC}-7${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-7${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-7${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}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
parallel:
matrix:
- FLAVOR:
- ''
- -servercore
- -linux
JMX:
- ''
- -jmx
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
deploy_containers-a7
deploy_containers-a7:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-7${JMX}-amd64,${IMG_BASE_SRC}-7${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-7${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-7${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}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
parallel:
matrix:
- FLAVOR:
- ''
- -servercore
- -linux
JMX:
- ''
- -jmx
rules:
- allow_failure: true
if: $BUCKET_BRANCH != "beta" && $BUCKET_BRANCH != "stable"
variables:
AGENT_REPOSITORY: agent-dev
DSD_REPOSITORY: dogstatsd-dev
IMG_REGISTRIES: dev
when: manual
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/ && $FORCE_MANUAL !=
"true"
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: on_success
- allow_failure: true
if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/ && $FORCE_MANUAL ==
"true"
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: manual
- allow_failure: true
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: manual
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
deploy_containers-a7-rc
deploy_containers-a7-rc:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-7${JMX}-amd64,${IMG_BASE_SRC}-7${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-7${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-7${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}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
parallel:
matrix:
- FLAVOR:
- ''
- -servercore
- -linux
JMX:
- ''
- -jmx
rules:
- allow_failure: true
if: $FORCE_MANUAL == "true" && $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: manual
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: on_success
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
VERSION: 7-rc
deploy_containers-a7_internal
deploy_containers-a7_internal:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-7${JMX}-amd64,${IMG_BASE_SRC}-7${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-7${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-7${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}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
rules:
- if: $BUCKET_BRANCH == "beta"
when: never
- if: $BUCKET_BRANCH != "beta" && $BUCKET_BRANCH != "stable"
when: never
- allow_failure: true
variables:
AGENT_REPOSITORY: ci/datadog-agent/agent-release
CLUSTER_AGENT_REPOSITORY: ci/datadog-agent/cluster-agent-release
CWS_INSTRUMENTATION_REPOSITORY: ci/datadog-agent/cws-instrumentation-release
DSD_REPOSITORY: ci/datadog-agent/dogstatsd-release
IMG_REGISTRIES: internal-aws-ddbuild
when: manual
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
JMX: -jmx
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
deploy_containers-a7_internal-rc
deploy_containers-a7_internal-rc:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_BASE_SRC="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}"
- export IMG_LINUX_SOURCES="${IMG_BASE_SRC}-7${JMX}-amd64,${IMG_BASE_SRC}-7${JMX}-arm64"
- export IMG_WINDOWS_SOURCES="${IMG_BASE_SRC}-7${JMX}-win1809${FLAVOR}-amd64,${IMG_BASE_SRC}-7${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}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
rules:
- allow_failure: true
if: $FORCE_MANUAL == "true" && $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/
variables:
AGENT_REPOSITORY: ci/datadog-agent/agent-release
CLUSTER_AGENT_REPOSITORY: ci/datadog-agent/cluster-agent-release
CWS_INSTRUMENTATION_REPOSITORY: ci/datadog-agent/cws-instrumentation-release
DSD_REPOSITORY: ci/datadog-agent/dogstatsd-release
IMG_REGISTRIES: internal-aws-ddbuild
when: manual
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/
variables:
AGENT_REPOSITORY: ci/datadog-agent/agent-release
CLUSTER_AGENT_REPOSITORY: ci/datadog-agent/cluster-agent-release
CWS_INSTRUMENTATION_REPOSITORY: ci/datadog-agent/cws-instrumentation-release
DSD_REPOSITORY: ci/datadog-agent/dogstatsd-release
IMG_REGISTRIES: internal-aws-ddbuild
when: on_success
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
VERSION: 7-rc
deploy_containers-dogstatsd
deploy_containers-dogstatsd:
before_script:
- - export VERSION="$(inv agent.version --major-version 7 --url-safe --pipeline-id
? -------
+ - VERSION="$(inv agent.version --major-version 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"
? ++++++++++++++++++++++
- $PARENT_PIPELINE_ID)"
+ || exit $?
- export IMG_SOURCES="${SRC_DSD}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-amd64,${SRC_DSD}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-arm64"
- export IMG_DESTINATIONS="${DSD_REPOSITORY}:${VERSION}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
rules:
- allow_failure: true
if: $BUCKET_BRANCH != "beta" && $BUCKET_BRANCH != "stable"
variables:
AGENT_REPOSITORY: agent-dev
DSD_REPOSITORY: dogstatsd-dev
IMG_REGISTRIES: dev
when: manual
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/ && $FORCE_MANUAL !=
"true"
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: on_success
- allow_failure: true
if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$/ && $FORCE_MANUAL ==
"true"
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: manual
- allow_failure: true
variables:
AGENT_REPOSITORY: agent
DSD_REPOSITORY: dogstatsd
IMG_REGISTRIES: public
when: manual
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
deploy_containers-ot
deploy_containers-ot:
before_script:
- - if [[ "$VERSION" == "" ]]; then export VERSION="$(inv agent.version --major-version
? -------
+ - if [[ "$VERSION" == "" ]]; then VERSION="$(inv agent.version --major-version 7
? ++
- 7 --url-safe --pipeline-id $PARENT_PIPELINE_ID)"; fi
? --
+ --url-safe --pipeline-id $PARENT_PIPELINE_ID)" || exit $?; fi
? +++++++++++
- export IMG_SOURCES="${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-7-ot-beta${JMX}-amd64,${SRC_AGENT}:v${PARENT_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}-7-ot-beta${JMX}-arm64"
- export IMG_DESTINATIONS="${AGENT_REPOSITORY}:${VERSION}-ot-beta${JMX}"
dependencies: []
image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES
parallel:
matrix:
- JMX:
- ''
- -jmx
rules:
- allow_failure: true
when: manual
script:
- GITLAB_TOKEN=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $GITLAB_SCHEDULER_TOKEN)
|| exit $?; export GITLAB_TOKEN
- "if [[ \"$BUCKET_BRANCH\" == \"nightly\" && ( \"$IMG_SOURCES\" =~ \"$SRC_AGENT\"\
\ || \"$IMG_SOURCES\" =~ \"$SRC_DCA\" || \"$IMG_SOURCES\" =~ \"$SRC_CWS_INSTRUMENTATION\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_AGENT\" || \"$IMG_VARIABLES\" =~ \"$SRC_DCA\"\
\ || \"$IMG_VARIABLES\" =~ \"$SRC_CWS_INSTRUMENTATION\" ) ]]; then\n export ECR_RELEASE_SUFFIX=\"\
-nightly\"\nelse\n export ECR_RELEASE_SUFFIX=\"${CI_COMMIT_TAG+-release}\"\n\
fi\n"
- IMG_VARIABLES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_VARIABLES")"
- IMG_SOURCES="$(sed -E "s#(${SRC_AGENT}|${SRC_DSD}|${SRC_DCA}|${SRC_CWS_INSTRUMENTATION})#\1${ECR_RELEASE_SUFFIX}#g"
<<<"$IMG_SOURCES")"
- inv pipeline.trigger-child-pipeline --project-name DataDog/public-images --git-ref
main --timeout 1800 --variable IMG_VARIABLES --variable IMG_REGISTRIES --variable
IMG_SOURCES --variable IMG_DESTINATIONS --variable IMG_SIGNING --variable APPS
--variable BAZEL_TARGET --variable DDR --variable DDR_WORKFLOW_ID --variable TARGET_ENV
--variable DYNAMIC_BUILD_RENDER_TARGET_FORWARD_PARAMETERS
stage: deploy_containers
tags:
- arch:amd64
variables:
AGENT_REPOSITORY: agent
IMG_REGISTRIES: public
IMG_SIGNING: ''
IMG_VARIABLES: ''
SRC_AGENT: registry.ddbuild.io/ci/datadog-agent/agent
SRC_CWS_INSTRUMENTATION: registry.ddbuild.io/ci/datadog-agent/cws-instrumentation
SRC_DCA: registry.ddbuild.io/ci/datadog-agent/cluster-agent
SRC_DSD: registry.ddbuild.io/ci/datadog-agent/dogstatsd
Changes Summary
Removed | Modified | Added | Renamed |
---|---|---|---|
0 | 8 | 0 | 0 |
ℹ️ Diff available in the job log.
[Fast Unit Tests Report] On pipeline 45107110 (CI Visibility). The following jobs did not run any unit tests: Jobs:
If you modified Go files and expected unit tests to run in these jobs, please double check the job logs. If you think tests should have been executed reach out to #agent-devx-help |
5f7d67b
to
c326449
Compare
Regression DetectorRegression Detector ResultsRun ID: 38d0d2be-eb46-4e51-825e-4ecd48247d4d Metrics dashboard Target profiles Baseline: 42db7b3 Performance changes are noted in the perf column of each table:
No significant changes in experiment optimization goalsConfidence level: 90.00% There were no significant changes in experiment optimization goals at this confidence level and effect size tolerance.
|
perf | experiment | goal | Δ mean % | Δ mean % CI | trials | links |
---|---|---|---|---|---|---|
➖ | pycheck_lots_of_tags | % cpu utilization | +0.69 | [-1.89, +3.27] | 1 | Logs |
➖ | tcp_syslog_to_blackhole | ingress throughput | +0.54 | [+0.49, +0.59] | 1 | Logs |
➖ | idle | memory utilization | +0.36 | [+0.31, +0.41] | 1 | Logs |
➖ | file_tree | memory utilization | +0.35 | [+0.27, +0.44] | 1 | Logs |
➖ | uds_dogstatsd_to_api_cpu | % cpu utilization | +0.11 | [-0.64, +0.86] | 1 | Logs |
➖ | otel_to_otel_logs | ingress throughput | +0.02 | [-0.78, +0.83] | 1 | Logs |
➖ | tcp_dd_logs_filter_exclude | ingress throughput | -0.00 | [-0.01, +0.01] | 1 | Logs |
➖ | uds_dogstatsd_to_api | ingress throughput | -0.02 | [-0.09, +0.05] | 1 | Logs |
➖ | basic_py_check | % cpu utilization | -0.11 | [-2.90, +2.68] | 1 | Logs |
Bounds Checks
perf | experiment | bounds_check_name | replicates_passed |
---|---|---|---|
✅ | idle | memory_usage | 10/10 |
Explanation
A regression test is an A/B test of target performance in a repeatable rig, where "performance" is measured as "comparison variant minus baseline variant" for an optimization goal (e.g., ingress throughput). Due to intrinsic variability in measuring that goal, we can only estimate its mean value for each experiment; we report uncertainty in that value as a 90.00% confidence interval denoted "Δ mean % CI".
For each experiment, we decide whether a change in performance is a "regression" -- a change worth investigating further -- if all of the following criteria are true:
-
Its estimated |Δ mean %| ≥ 5.00%, indicating the change is big enough to merit a closer look.
-
Its 90.00% confidence interval "Δ mean % CI" does not contain zero, indicating that if our statistical model is accurate, there is at least a 90.00% chance there is a difference in performance between baseline and comparison variants.
-
Its configuration does not mark it "erratic".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
/merge |
🚂 MergeQueue: pull request added to the queue The median merge time in Use |
What does this PR do?
Added an
Exit(code=42)
on python invoke tasks callingaws
cli during the pipeline.And throw that exit code in the gitlab script call (using
command || exit $?
) as this is currently mandatory for gitlab to get the correct error code.Motivation
acix-435 - Follow-up of #29262. In some situation the first call to
aws
cli is not a call toaws ssm
butaws cp
. With addition of theExit(code=42)
, if these tasks fail the job will be retriedDescribe how to test/QA your changes
We can only validate I didn't change the current behaviour. We can validate with a log search of looking at retried job executions, which is tedious. Otherwise we can just monitor if any "Unable to locate credential" issue re-occurs in the pipeline.
Possible Drawbacks / Trade-offs
In some modified calls there are still some other
aws
commands called first, this will come in a next PRAdditional Notes
I took the opportunity to remove unnecessary
export
keywords