diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index fd4342188f69d..34410bdad0264 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -11,7 +11,6 @@ include: - .gitlab/powershell_script_deploy/powershell_script_deploy.yml - .gitlab/common/shared.yml - .gitlab/common/skip_ci_check.yml - - .gitlab/common/pr_commenter.yml - .gitlab/common/test_infra_version.yml - .gitlab/container_build/include.yml - .gitlab/container_scan/container_scan.yml diff --git a/.gitlab/common/pr_commenter.yml b/.gitlab/common/pr_commenter.yml deleted file mode 100644 index 75728807ae0c4..0000000000000 --- a/.gitlab/common/pr_commenter.yml +++ /dev/null @@ -1,22 +0,0 @@ ---- -.install_pr_commenter: - # Add janky means of installing PR commenter borrowed from - # https://github.com/DataDog/dogweb/blob/45d7fcf035d0d515ebd901919099d4c8bfa82829/docker/docker-builder/Dockerfile#L69-L77 - - apt-get update - - apt-get install -y curl - - curl -OL https://s3.amazonaws.com/dd-package-public/dd-package.deb - - dpkg -i dd-package.deb - - rm dd-package.deb - - apt-get update - - dd-package --bucket binaries.ddbuild.io --package devtools/dd-package-dev --distribution "20.04" - # Kludge from https://gitlab.com/gitlab-org/gitlab-runner/-/issues/4645#note_287636439 to avoid - # doubled output - - echo "" - - "####################### NOTE TO MAINTAINERS #####################################" - - "# Ignore bdist_wheel build error raised when installing 'devtools/pr-commenter' #" - - "# This error is known behavior, and you should see a successful install #" - - "# beneath the error message in the GitLab CI logs #" - - "#################################################################################" - - echo "" - # Pinned version of pr-commenter taken from https://github.com/DataDog/dogweb/blob/b249c0815f70e71e07846f5e42fb6504c17a7c3e/tasks/gitlab/k8s-diff-helper.sh#L22 - - dd-package --bucket binaries.ddbuild.io --package devtools/pr-commenter --distribution "20.04" --version "16841676-368d2e2d" diff --git a/.gitlab/notify/notify.yml b/.gitlab/notify/notify.yml index 7e462acade34b..f8ead69079c91 100644 --- a/.gitlab/notify/notify.yml +++ b/.gitlab/notify/notify.yml @@ -59,8 +59,8 @@ send_pipeline_stats: notify_github: stage: notify - image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/docker_x64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES - tags: ["arch:amd64"] + image: 486234852809.dkr.ecr.us-east-1.amazonaws.com/ci/datadog-agent-buildimages/deb_arm64$DATADOG_AGENT_BUILDIMAGES_SUFFIX:$DATADOG_AGENT_BUILDIMAGES + tags: ["arch:arm64"] rules: - !reference [.except_mergequeue] - !reference [.except_main_or_release_branch] @@ -78,14 +78,15 @@ notify_github: dependencies: [] allow_failure: true script: - - !reference [.install_pr_commenter] + - !reference [.setup_agent_github_app] + - python3 -m pip install -r tasks/libs/requirements-github.txt - messagefile="$(mktemp)" - echo "Use this command from [test-infra-definitions](https://github.com/DataDog/test-infra-definitions) to manually test this PR changes on a VM:" >> "$messagefile" - echo '```sh' >> "$messagefile" - echo "inv create-vm --pipeline-id=$CI_PIPELINE_ID --os-family=ubuntu" >> "$messagefile" - echo '```' >> "$messagefile" - 'echo "Note: This applies to commit **$CI_COMMIT_SHORT_SHA**" >> "$messagefile"' - - cat "$messagefile" | /usr/local/bin/pr-commenter --for-pr="$CI_COMMIT_REF_NAME" --header="Test changes on VM" + - inv -e github.pr-commenter --title "Test changes on VM" --body "$(cat "$messagefile")" --echo - rm "$messagefile" notify_gitlab_ci_changes: