2020-07-17 16:51:32 +02:00
|
|
|
name: Build
|
|
|
|
|
|
|
|
on:
|
2021-05-04 22:41:49 +02:00
|
|
|
workflow_dispatch:
|
2024-01-23 19:24:52 +01:00
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- "main"
|
|
|
|
- "rc"
|
|
|
|
- "hotfix-rc"
|
|
|
|
pull_request:
|
2020-07-17 16:51:32 +02:00
|
|
|
|
2023-08-10 19:41:56 +02:00
|
|
|
env:
|
2023-08-11 14:49:04 +02:00
|
|
|
_AZ_REGISTRY: "bitwardenprod.azurecr.io"
|
2023-08-10 19:41:56 +02:00
|
|
|
|
2020-07-17 16:51:32 +02:00
|
|
|
jobs:
|
2022-03-14 14:31:03 +01:00
|
|
|
lint:
|
|
|
|
name: Lint
|
2022-11-18 20:39:01 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2022-03-14 14:31:03 +01:00
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Check out repo
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
2022-03-14 14:31:03 +01:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Set up .NET
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/setup-dotnet@3e891b0cb619bf60e2c25674b222b8940e2c1c25 # v4.1.0
|
2023-08-14 17:40:27 +02:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Verify format
|
2022-06-24 16:39:34 +02:00
|
|
|
run: dotnet format --verify-no-changes
|
2022-03-14 14:31:03 +01:00
|
|
|
|
2021-09-25 00:04:14 +02:00
|
|
|
build-artifacts:
|
|
|
|
name: Build artifacts
|
2022-11-18 20:39:01 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2022-07-19 15:35:26 +02:00
|
|
|
needs:
|
2022-07-11 23:30:52 +02:00
|
|
|
- lint
|
2021-09-25 00:04:14 +02:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
include:
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Admin
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2022-03-03 23:53:09 +01:00
|
|
|
node: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Api
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Billing
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Events
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: EventsProcessor
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Icons
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Identity
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2023-08-10 19:41:56 +02:00
|
|
|
- project_name: MsSqlMigratorUtility
|
|
|
|
base_path: ./util
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Notifications
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./src
|
2023-08-10 19:41:56 +02:00
|
|
|
- project_name: Scim
|
|
|
|
base_path: ./bitwarden_license/src
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Server
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./util
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Setup
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./util
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Sso
|
2021-09-25 00:04:14 +02:00
|
|
|
base_path: ./bitwarden_license/src
|
2022-03-03 23:53:09 +01:00
|
|
|
node: true
|
2021-09-25 00:04:14 +02:00
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Check out repo
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
2021-09-25 00:04:14 +02:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Set up .NET
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/setup-dotnet@3e891b0cb619bf60e2c25674b222b8940e2c1c25 # v4.1.0
|
2023-08-14 17:40:27 +02:00
|
|
|
|
2021-09-25 00:04:14 +02:00
|
|
|
- name: Set up Node
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
|
2021-09-25 00:04:14 +02:00
|
|
|
with:
|
2022-10-04 23:23:43 +02:00
|
|
|
cache: "npm"
|
|
|
|
cache-dependency-path: "**/package-lock.json"
|
|
|
|
node-version: "16"
|
2021-09-25 00:04:14 +02:00
|
|
|
|
|
|
|
- name: Print environment
|
|
|
|
run: |
|
|
|
|
whoami
|
|
|
|
dotnet --info
|
|
|
|
node --version
|
|
|
|
npm --version
|
|
|
|
echo "GitHub ref: $GITHUB_REF"
|
|
|
|
echo "GitHub event: $GITHUB_EVENT"
|
|
|
|
|
2022-03-03 23:53:09 +01:00
|
|
|
- name: Build node
|
|
|
|
if: ${{ matrix.node }}
|
2022-11-18 20:39:01 +01:00
|
|
|
working-directory: ${{ matrix.base_path }}/${{ matrix.project_name }}
|
2021-09-25 00:04:14 +02:00
|
|
|
run: |
|
2022-03-03 23:53:09 +01:00
|
|
|
npm ci
|
|
|
|
npm run build
|
2021-09-25 00:04:14 +02:00
|
|
|
|
2022-11-18 20:39:01 +01:00
|
|
|
- name: Publish project
|
|
|
|
working-directory: ${{ matrix.base_path }}/${{ matrix.project_name }}
|
2021-09-25 00:04:14 +02:00
|
|
|
run: |
|
|
|
|
echo "Publish"
|
|
|
|
dotnet publish -c "Release" -o obj/build-output/publish
|
|
|
|
|
|
|
|
cd obj/build-output/publish
|
2022-11-18 20:39:01 +01:00
|
|
|
zip -r ${{ matrix.project_name }}.zip .
|
|
|
|
mv ${{ matrix.project_name }}.zip ../../../
|
2021-09-25 00:04:14 +02:00
|
|
|
|
|
|
|
pwd
|
|
|
|
ls -atlh ../../../
|
|
|
|
|
2022-11-18 20:39:01 +01:00
|
|
|
- name: Upload project artifact
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2021-09-25 00:04:14 +02:00
|
|
|
with:
|
2022-11-18 20:39:01 +01:00
|
|
|
name: ${{ matrix.project_name }}.zip
|
|
|
|
path: ${{ matrix.base_path }}/${{ matrix.project_name }}/${{ matrix.project_name }}.zip
|
2021-09-25 00:04:14 +02:00
|
|
|
if-no-files-found: error
|
|
|
|
|
|
|
|
build-docker:
|
|
|
|
name: Build Docker images
|
2022-11-18 20:39:01 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2024-02-23 19:47:23 +01:00
|
|
|
permissions:
|
|
|
|
security-events: write
|
2021-09-25 00:04:14 +02:00
|
|
|
needs: build-artifacts
|
2021-05-27 16:32:36 +02:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
include:
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Admin
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./src
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Api
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./src
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Attachments
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./util
|
2023-08-10 19:41:56 +02:00
|
|
|
- project_name: Billing
|
|
|
|
base_path: ./src
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Events
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./src
|
2021-06-14 20:11:05 +02:00
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: EventsProcessor
|
2021-06-14 20:11:05 +02:00
|
|
|
base_path: ./src
|
2021-05-27 16:32:36 +02:00
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Icons
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./src
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Identity
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./src
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: MsSql
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./util
|
2023-08-10 19:41:56 +02:00
|
|
|
- project_name: MsSqlMigratorUtility
|
|
|
|
base_path: ./util
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Nginx
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./util
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Notifications
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./src
|
2023-08-10 19:41:56 +02:00
|
|
|
dotnet: true
|
|
|
|
- project_name: Scim
|
|
|
|
base_path: ./bitwarden_license/src
|
2021-05-27 16:32:36 +02:00
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Server
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./util
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Setup
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./util
|
|
|
|
dotnet: true
|
2022-11-18 20:39:01 +01:00
|
|
|
- project_name: Sso
|
2021-05-27 16:32:36 +02:00
|
|
|
base_path: ./bitwarden_license/src
|
2023-05-16 17:31:02 +02:00
|
|
|
dotnet: true
|
2020-07-17 16:51:32 +02:00
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Check out repo
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
2023-02-15 11:45:46 +01:00
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Check branch to publish
|
2023-02-16 23:16:32 +01:00
|
|
|
env:
|
2023-12-12 21:08:12 +01:00
|
|
|
PUBLISH_BRANCHES: "main,rc,hotfix-rc"
|
2023-02-16 23:16:32 +01:00
|
|
|
id: publish-branch-check
|
2023-01-30 22:12:09 +01:00
|
|
|
run: |
|
2023-02-16 23:16:32 +01:00
|
|
|
IFS="," read -a publish_branches <<< $PUBLISH_BRANCHES
|
2021-05-27 16:32:36 +02:00
|
|
|
|
2023-02-16 23:16:32 +01:00
|
|
|
if [[ " ${publish_branches[*]} " =~ " ${GITHUB_REF:11} " ]]; then
|
|
|
|
echo "is_publish_branch=true" >> $GITHUB_ENV
|
|
|
|
else
|
|
|
|
echo "is_publish_branch=false" >> $GITHUB_ENV
|
|
|
|
fi
|
2021-06-14 20:11:05 +02:00
|
|
|
|
2023-02-16 23:16:32 +01:00
|
|
|
########## ACRs ##########
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Log in to Azure - production subscription
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
2023-01-30 22:12:09 +01:00
|
|
|
with:
|
|
|
|
creds: ${{ secrets.AZURE_PROD_KV_CREDENTIALS }}
|
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Log in to ACR - production subscription
|
2023-01-30 22:12:09 +01:00
|
|
|
run: az acr login -n bitwardenprod
|
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Log in to Azure - CI subscription
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
2023-04-17 15:06:57 +02:00
|
|
|
with:
|
2023-04-17 19:03:32 +02:00
|
|
|
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }}
|
2023-04-17 15:06:57 +02:00
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Retrieve GitHub PAT secrets
|
2023-02-16 23:16:32 +01:00
|
|
|
id: retrieve-secret-pat
|
2023-11-08 19:08:15 +01:00
|
|
|
uses: bitwarden/gh-actions/get-keyvault-secrets@main
|
2022-01-24 20:12:37 +01:00
|
|
|
with:
|
2023-04-17 15:06:57 +02:00
|
|
|
keyvault: "bitwarden-ci"
|
2023-02-16 23:16:32 +01:00
|
|
|
secrets: "github-pat-bitwarden-devops-bot-repo-scope"
|
2022-01-24 20:12:37 +01:00
|
|
|
|
2023-02-16 23:16:32 +01:00
|
|
|
########## Generate image tag and build Docker image ##########
|
|
|
|
- name: Generate Docker image tag
|
|
|
|
id: tag
|
|
|
|
run: |
|
2024-01-23 22:03:11 +01:00
|
|
|
if [[ $(grep "pull" <<< "${GITHUB_REF}") ]]; then
|
|
|
|
IMAGE_TAG=$(echo "${GITHUB_HEAD_REF}" | sed "s#/#-#g")
|
|
|
|
else
|
|
|
|
IMAGE_TAG=$(echo "${GITHUB_REF:11}" | sed "s#/#-#g")
|
|
|
|
fi
|
|
|
|
|
2023-12-12 21:08:12 +01:00
|
|
|
if [[ "$IMAGE_TAG" == "main" ]]; then
|
2023-02-16 23:16:32 +01:00
|
|
|
IMAGE_TAG=dev
|
|
|
|
fi
|
2024-01-23 22:03:11 +01:00
|
|
|
|
2023-02-16 23:16:32 +01:00
|
|
|
echo "image_tag=$IMAGE_TAG" >> $GITHUB_OUTPUT
|
2024-01-23 22:03:11 +01:00
|
|
|
echo "### :mega: Docker Image Tag: $IMAGE_TAG" >> $GITHUB_STEP_SUMMARY
|
2023-02-16 23:16:32 +01:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Set up project name
|
2023-02-16 23:16:32 +01:00
|
|
|
id: setup
|
|
|
|
run: |
|
|
|
|
PROJECT_NAME=$(echo "${{ matrix.project_name }}" | awk '{print tolower($0)}')
|
|
|
|
echo "Matrix name: ${{ matrix.project_name }}"
|
|
|
|
echo "PROJECT_NAME: $PROJECT_NAME"
|
|
|
|
echo "project_name=$PROJECT_NAME" >> $GITHUB_OUTPUT
|
|
|
|
|
2024-02-23 22:09:51 +01:00
|
|
|
- name: Generate image tags(s)
|
|
|
|
id: image-tags
|
2022-01-24 21:42:14 +01:00
|
|
|
env:
|
2023-02-16 23:16:32 +01:00
|
|
|
IMAGE_TAG: ${{ steps.tag.outputs.image_tag }}
|
2022-11-18 20:39:01 +01:00
|
|
|
PROJECT_NAME: ${{ steps.setup.outputs.project_name }}
|
2023-12-07 15:42:35 +01:00
|
|
|
SHA: ${{ github.sha }}
|
|
|
|
run: |
|
2024-02-23 22:09:51 +01:00
|
|
|
TAGS="${_AZ_REGISTRY}/${PROJECT_NAME}:${IMAGE_TAG}"
|
|
|
|
echo "primary_tag=$TAGS" >> $GITHUB_OUTPUT
|
2023-12-07 15:42:35 +01:00
|
|
|
if [[ "${IMAGE_TAG}" == "dev" ]]; then
|
|
|
|
SHORT_SHA=$(git rev-parse --short ${SHA})
|
2024-02-23 22:09:51 +01:00
|
|
|
TAGS=$TAGS",${_AZ_REGISTRY}/${PROJECT_NAME}:dev-${SHORT_SHA}"
|
2023-12-07 15:42:35 +01:00
|
|
|
fi
|
2024-02-23 22:09:51 +01:00
|
|
|
echo "tags=$TAGS" >> $GITHUB_OUTPUT
|
2023-02-16 23:16:32 +01:00
|
|
|
|
|
|
|
- name: Get build artifact
|
|
|
|
if: ${{ matrix.dotnet }}
|
2024-08-26 22:47:35 +02:00
|
|
|
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
|
2023-02-16 23:16:32 +01:00
|
|
|
with:
|
|
|
|
name: ${{ matrix.project_name }}.zip
|
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Set up build artifact
|
2023-02-16 23:16:32 +01:00
|
|
|
if: ${{ matrix.dotnet }}
|
|
|
|
run: |
|
|
|
|
mkdir -p ${{ matrix.base_path}}/${{ matrix.project_name }}/obj/build-output/publish
|
|
|
|
unzip ${{ matrix.project_name }}.zip \
|
|
|
|
-d ${{ matrix.base_path }}/${{ matrix.project_name }}/obj/build-output/publish
|
|
|
|
|
|
|
|
- name: Build Docker image
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: docker/build-push-action@4f58ea79222b3b9dc2c8bbdd6debcef730109a75 # v6.9.0
|
2023-02-16 23:16:32 +01:00
|
|
|
with:
|
|
|
|
context: ${{ matrix.base_path }}/${{ matrix.project_name }}
|
|
|
|
file: ${{ matrix.base_path }}/${{ matrix.project_name }}/Dockerfile
|
|
|
|
platforms: linux/amd64
|
|
|
|
push: true
|
2024-02-23 22:09:51 +01:00
|
|
|
tags: ${{ steps.image-tags.outputs.tags }}
|
2023-02-16 23:16:32 +01:00
|
|
|
secrets: |
|
|
|
|
"GH_PAT=${{ steps.retrieve-secret-pat.outputs.github-pat-bitwarden-devops-bot-repo-scope }}"
|
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Scan Docker image
|
|
|
|
id: container-scan
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: anchore/scan-action@5ed195cc06065322983cae4bb31e2a751feb86fd # v5.2.0
|
2024-02-23 19:47:23 +01:00
|
|
|
with:
|
2024-02-23 22:09:51 +01:00
|
|
|
image: ${{ steps.image-tags.outputs.primary_tag }}
|
2024-02-23 19:47:23 +01:00
|
|
|
fail-build: false
|
|
|
|
output-format: sarif
|
|
|
|
|
|
|
|
- name: Upload Grype results to GitHub
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: github/codeql-action/upload-sarif@662472033e021d55d94146f66f6058822b0b39fd # v3.27.0
|
2024-02-23 19:47:23 +01:00
|
|
|
with:
|
|
|
|
sarif_file: ${{ steps.container-scan.outputs.sarif }}
|
|
|
|
|
2021-05-27 16:32:36 +02:00
|
|
|
upload:
|
|
|
|
name: Upload
|
2022-11-18 20:39:01 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2021-09-25 00:04:14 +02:00
|
|
|
needs: build-docker
|
2021-05-27 16:32:36 +02:00
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Check out repo
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
2023-08-14 17:40:27 +02:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Set up .NET
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/setup-dotnet@3e891b0cb619bf60e2c25674b222b8940e2c1c25 # v4.1.0
|
2023-08-14 17:40:27 +02:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Log in to Azure - production subscription
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
2023-08-10 19:41:56 +02:00
|
|
|
with:
|
|
|
|
creds: ${{ secrets.AZURE_PROD_KV_CREDENTIALS }}
|
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Log in to ACR - production subscription
|
2023-08-10 19:41:56 +02:00
|
|
|
run: az acr login -n $_AZ_REGISTRY --only-show-errors
|
|
|
|
|
2023-07-31 19:14:33 +02:00
|
|
|
- name: Make Docker stubs
|
2023-12-12 21:08:12 +01:00
|
|
|
if: github.ref == 'refs/heads/main' ||
|
2022-03-16 16:18:35 +01:00
|
|
|
github.ref == 'refs/heads/rc' ||
|
|
|
|
github.ref == 'refs/heads/hotfix-rc'
|
2020-07-17 16:51:32 +02:00
|
|
|
run: |
|
2023-08-10 22:49:39 +02:00
|
|
|
# Set proper setup image based on branch
|
2024-10-17 17:50:31 +02:00
|
|
|
case "$GITHUB_REF" in
|
2023-12-12 21:08:12 +01:00
|
|
|
"refs/heads/main")
|
2023-08-10 22:49:39 +02:00
|
|
|
SETUP_IMAGE="$_AZ_REGISTRY/setup:dev"
|
|
|
|
;;
|
|
|
|
"refs/heads/rc")
|
|
|
|
SETUP_IMAGE="$_AZ_REGISTRY/setup:rc"
|
|
|
|
;;
|
|
|
|
"refs/heads/hotfix-rc")
|
|
|
|
SETUP_IMAGE="$_AZ_REGISTRY/setup:hotfix-rc"
|
|
|
|
;;
|
|
|
|
esac
|
2021-07-02 19:22:51 +02:00
|
|
|
|
2020-07-17 16:51:32 +02:00
|
|
|
STUB_OUTPUT=$(pwd)/docker-stub
|
2023-07-31 19:14:33 +02:00
|
|
|
|
|
|
|
# Run setup
|
|
|
|
docker run -i --rm --name setup -v $STUB_OUTPUT/US:/bitwarden $SETUP_IMAGE \
|
|
|
|
dotnet Setup.dll -stub 1 -install 1 -domain bitwarden.example.com -os lin -cloud-region US
|
|
|
|
docker run -i --rm --name setup -v $STUB_OUTPUT/EU:/bitwarden $SETUP_IMAGE \
|
|
|
|
dotnet Setup.dll -stub 1 -install 1 -domain bitwarden.example.com -os lin -cloud-region EU
|
|
|
|
|
2020-07-17 17:19:00 +02:00
|
|
|
sudo chown -R $(whoami):$(whoami) $STUB_OUTPUT
|
2020-07-17 16:51:32 +02:00
|
|
|
|
2023-07-31 20:12:09 +02:00
|
|
|
# Remove extra directories and files
|
2023-07-31 19:14:33 +02:00
|
|
|
rm -rf $STUB_OUTPUT/US/letsencrypt
|
|
|
|
rm -rf $STUB_OUTPUT/EU/letsencrypt
|
|
|
|
rm $STUB_OUTPUT/US/env/uid.env $STUB_OUTPUT/US/config.yml
|
|
|
|
rm $STUB_OUTPUT/EU/env/uid.env $STUB_OUTPUT/EU/config.yml
|
|
|
|
|
|
|
|
# Create uid environment files
|
|
|
|
touch $STUB_OUTPUT/US/env/uid.env
|
|
|
|
touch $STUB_OUTPUT/EU/env/uid.env
|
|
|
|
|
|
|
|
# Zip up the Docker stub files
|
|
|
|
cd docker-stub/US; zip -r ../../docker-stub-US.zip *; cd ../..
|
|
|
|
cd docker-stub/EU; zip -r ../../docker-stub-EU.zip *; cd ../..
|
|
|
|
|
|
|
|
- name: Make Docker stub checksums
|
2023-12-12 21:08:12 +01:00
|
|
|
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/rc' || github.ref == 'refs/heads/hotfix-rc'
|
2023-07-31 19:14:33 +02:00
|
|
|
run: |
|
|
|
|
sha256sum docker-stub-US.zip > docker-stub-US-sha256.txt
|
|
|
|
sha256sum docker-stub-EU.zip > docker-stub-EU-sha256.txt
|
|
|
|
|
|
|
|
- name: Upload Docker stub US artifact
|
2023-12-12 21:08:12 +01:00
|
|
|
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/rc' || github.ref == 'refs/heads/hotfix-rc'
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2023-07-31 19:14:33 +02:00
|
|
|
with:
|
|
|
|
name: docker-stub-US.zip
|
|
|
|
path: docker-stub-US.zip
|
|
|
|
if-no-files-found: error
|
|
|
|
|
|
|
|
- name: Upload Docker stub EU artifact
|
2023-12-12 21:08:12 +01:00
|
|
|
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/rc' || github.ref == 'refs/heads/hotfix-rc'
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2023-07-31 19:14:33 +02:00
|
|
|
with:
|
|
|
|
name: docker-stub-EU.zip
|
|
|
|
path: docker-stub-EU.zip
|
|
|
|
if-no-files-found: error
|
2022-02-28 15:38:59 +01:00
|
|
|
|
2023-07-31 19:14:33 +02:00
|
|
|
- name: Upload Docker stub US checksum artifact
|
2023-12-12 21:08:12 +01:00
|
|
|
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/rc' || github.ref == 'refs/heads/hotfix-rc'
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2020-07-17 16:51:32 +02:00
|
|
|
with:
|
2023-07-31 19:14:33 +02:00
|
|
|
name: docker-stub-US-sha256.txt
|
|
|
|
path: docker-stub-US-sha256.txt
|
2022-02-28 15:38:59 +01:00
|
|
|
if-no-files-found: error
|
|
|
|
|
2023-07-31 19:14:33 +02:00
|
|
|
- name: Upload Docker stub EU checksum artifact
|
2023-12-12 21:08:12 +01:00
|
|
|
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/rc' || github.ref == 'refs/heads/hotfix-rc'
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2022-02-28 15:38:59 +01:00
|
|
|
with:
|
2023-07-31 19:14:33 +02:00
|
|
|
name: docker-stub-EU-sha256.txt
|
|
|
|
path: docker-stub-EU-sha256.txt
|
2021-07-02 22:34:20 +02:00
|
|
|
if-no-files-found: error
|
2020-07-17 16:51:32 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
- name: Build Public API Swagger
|
2020-07-17 17:19:00 +02:00
|
|
|
run: |
|
|
|
|
cd ./src/Api
|
2023-12-27 16:36:20 +01:00
|
|
|
echo "Restore tools"
|
|
|
|
dotnet tool restore
|
2021-05-27 16:32:36 +02:00
|
|
|
echo "Publish"
|
2021-05-27 18:16:12 +02:00
|
|
|
dotnet publish -c "Release" -o obj/build-output/publish
|
2021-05-27 16:32:36 +02:00
|
|
|
|
|
|
|
dotnet swagger tofile --output ../../swagger.json --host https://api.bitwarden.com \
|
2021-05-27 18:16:12 +02:00
|
|
|
./obj/build-output/publish/Api.dll public
|
2020-07-17 17:19:00 +02:00
|
|
|
cd ../..
|
|
|
|
env:
|
|
|
|
ASPNETCORE_ENVIRONMENT: Production
|
2022-10-04 23:23:43 +02:00
|
|
|
swaggerGen: "True"
|
2022-02-23 19:29:17 +01:00
|
|
|
DOTNET_ROLL_FORWARD_ON_NO_CANDIDATE_FX: 2
|
2023-01-13 15:02:53 +01:00
|
|
|
GLOBALSETTINGS__SQLSERVER__CONNECTIONSTRING: "placeholder"
|
2020-07-17 17:19:00 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
- name: Upload Public API Swagger artifact
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2020-07-17 17:19:00 +02:00
|
|
|
with:
|
|
|
|
name: swagger.json
|
2022-02-28 15:38:59 +01:00
|
|
|
path: swagger.json
|
2021-07-02 22:34:20 +02:00
|
|
|
if-no-files-found: error
|
2024-10-21 14:11:59 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
- name: Build Internal API Swagger
|
|
|
|
run: |
|
|
|
|
cd ./src/Api
|
|
|
|
echo "Restore API tools"
|
|
|
|
dotnet tool restore
|
|
|
|
echo "Publish API"
|
|
|
|
dotnet publish -c "Release" -o obj/build-output/publish
|
2024-10-21 14:11:59 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
dotnet swagger tofile --output ../../internal.json --host https://api.bitwarden.com \
|
|
|
|
./obj/build-output/publish/Api.dll internal
|
2024-10-21 14:11:59 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
cd ../Identity
|
2024-10-21 14:11:59 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
echo "Restore Identity tools"
|
|
|
|
dotnet tool restore
|
|
|
|
echo "Publish Identity"
|
|
|
|
dotnet publish -c "Release" -o obj/build-output/publish
|
2024-10-21 14:11:59 +02:00
|
|
|
|
2024-08-20 15:34:22 +02:00
|
|
|
dotnet swagger tofile --output ../../identity.json --host https://identity.bitwarden.com \
|
|
|
|
./obj/build-output/publish/Identity.dll v1
|
|
|
|
cd ../..
|
|
|
|
env:
|
|
|
|
ASPNETCORE_ENVIRONMENT: Development
|
|
|
|
swaggerGen: "True"
|
|
|
|
DOTNET_ROLL_FORWARD_ON_NO_CANDIDATE_FX: 2
|
|
|
|
GLOBALSETTINGS__SQLSERVER__CONNECTIONSTRING: "placeholder"
|
|
|
|
|
|
|
|
- name: Upload Internal API Swagger artifact
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2024-08-20 15:34:22 +02:00
|
|
|
with:
|
|
|
|
name: internal.json
|
|
|
|
path: internal.json
|
|
|
|
if-no-files-found: error
|
|
|
|
|
|
|
|
- name: Upload Identity Swagger artifact
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2024-08-20 15:34:22 +02:00
|
|
|
with:
|
|
|
|
name: identity.json
|
|
|
|
path: identity.json
|
2024-10-21 14:11:59 +02:00
|
|
|
if-no-files-found: error
|
2021-10-13 21:50:40 +02:00
|
|
|
|
2023-03-07 14:10:34 +01:00
|
|
|
build-mssqlmigratorutility:
|
2024-01-23 19:24:52 +01:00
|
|
|
name: Build MSSQL migrator utility
|
2023-03-07 14:10:34 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2023-08-10 19:41:56 +02:00
|
|
|
needs: lint
|
2023-03-07 14:10:34 +01:00
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
shell: bash
|
|
|
|
working-directory: "util/MsSqlMigratorUtility"
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
target:
|
|
|
|
- osx-x64
|
|
|
|
- linux-x64
|
|
|
|
- win-x64
|
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Check out repo
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
2023-03-07 14:10:34 +01:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Set up .NET
|
2024-10-30 16:23:50 +01:00
|
|
|
uses: actions/setup-dotnet@3e891b0cb619bf60e2c25674b222b8940e2c1c25 # v4.1.0
|
2023-08-14 17:40:27 +02:00
|
|
|
|
2023-03-07 14:10:34 +01:00
|
|
|
- name: Print environment
|
|
|
|
run: |
|
|
|
|
whoami
|
|
|
|
dotnet --info
|
|
|
|
echo "GitHub ref: $GITHUB_REF"
|
|
|
|
echo "GitHub event: $GITHUB_EVENT"
|
|
|
|
|
|
|
|
- name: Publish project
|
2023-08-10 19:41:56 +02:00
|
|
|
run: |
|
|
|
|
dotnet publish -c "Release" -o obj/build-output/publish -r ${{ matrix.target }} -p:PublishSingleFile=true \
|
|
|
|
-p:IncludeNativeLibrariesForSelfExtract=true --self-contained true
|
2023-03-07 14:10:34 +01:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Upload project artifact for Windows
|
2023-03-07 14:10:34 +01:00
|
|
|
if: ${{ contains(matrix.target, 'win') == true }}
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2023-03-07 14:10:34 +01:00
|
|
|
with:
|
|
|
|
name: MsSqlMigratorUtility-${{ matrix.target }}
|
|
|
|
path: util/MsSqlMigratorUtility/obj/build-output/publish/MsSqlMigratorUtility.exe
|
|
|
|
if-no-files-found: error
|
|
|
|
|
|
|
|
- name: Upload project artifact
|
|
|
|
if: ${{ contains(matrix.target, 'win') == false }}
|
2024-10-17 16:42:44 +02:00
|
|
|
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
2023-03-07 14:10:34 +01:00
|
|
|
with:
|
|
|
|
name: MsSqlMigratorUtility-${{ matrix.target }}
|
|
|
|
path: util/MsSqlMigratorUtility/obj/build-output/publish/MsSqlMigratorUtility
|
|
|
|
if-no-files-found: error
|
|
|
|
|
2023-06-27 19:18:51 +02:00
|
|
|
self-host-build:
|
2023-08-30 00:22:09 +02:00
|
|
|
name: Trigger self-host build
|
|
|
|
runs-on: ubuntu-22.04
|
2023-12-19 18:05:02 +01:00
|
|
|
needs: build-docker
|
2023-08-30 00:22:09 +02:00
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Log in to Azure - CI subscription
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
2023-08-30 00:22:09 +02:00
|
|
|
with:
|
|
|
|
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }}
|
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Retrieve GitHub PAT secrets
|
2023-08-30 00:22:09 +02:00
|
|
|
id: retrieve-secret-pat
|
2023-11-08 19:08:15 +01:00
|
|
|
uses: bitwarden/gh-actions/get-keyvault-secrets@main
|
2023-08-30 00:22:09 +02:00
|
|
|
with:
|
|
|
|
keyvault: "bitwarden-ci"
|
|
|
|
secrets: "github-pat-bitwarden-devops-bot-repo-scope"
|
|
|
|
|
|
|
|
- name: Trigger self-host build
|
2024-08-26 22:47:10 +02:00
|
|
|
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
2023-08-30 00:22:09 +02:00
|
|
|
with:
|
|
|
|
github-token: ${{ steps.retrieve-secret-pat.outputs.github-pat-bitwarden-devops-bot-repo-scope }}
|
|
|
|
script: |
|
|
|
|
await github.rest.actions.createWorkflowDispatch({
|
|
|
|
owner: 'bitwarden',
|
|
|
|
repo: 'self-host',
|
|
|
|
workflow_id: 'build-unified.yml',
|
2023-12-12 21:08:12 +01:00
|
|
|
ref: 'main',
|
2023-08-30 00:22:09 +02:00
|
|
|
inputs: {
|
2024-10-17 17:50:31 +02:00
|
|
|
server_branch: process.env.GITHUB_REF
|
2023-08-30 00:22:09 +02:00
|
|
|
}
|
2024-10-17 17:50:31 +02:00
|
|
|
});
|
2023-06-23 09:23:47 +02:00
|
|
|
|
2023-12-19 18:05:02 +01:00
|
|
|
trigger-k8s-deploy:
|
|
|
|
name: Trigger k8s deploy
|
|
|
|
if: github.ref == 'refs/heads/main'
|
|
|
|
runs-on: ubuntu-22.04
|
|
|
|
needs: build-docker
|
|
|
|
steps:
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Log in to Azure - CI subscription
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
2023-12-19 18:05:02 +01:00
|
|
|
with:
|
|
|
|
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }}
|
|
|
|
|
2024-02-23 19:47:23 +01:00
|
|
|
- name: Retrieve GitHub PAT secrets
|
2023-12-19 18:05:02 +01:00
|
|
|
id: retrieve-secret-pat
|
|
|
|
uses: bitwarden/gh-actions/get-keyvault-secrets@main
|
|
|
|
with:
|
|
|
|
keyvault: "bitwarden-ci"
|
|
|
|
secrets: "github-pat-bitwarden-devops-bot-repo-scope"
|
|
|
|
|
|
|
|
- name: Trigger k8s deploy
|
2024-08-26 22:47:10 +02:00
|
|
|
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
2023-12-19 18:05:02 +01:00
|
|
|
with:
|
|
|
|
github-token: ${{ steps.retrieve-secret-pat.outputs.github-pat-bitwarden-devops-bot-repo-scope }}
|
|
|
|
script: |
|
|
|
|
await github.rest.actions.createWorkflowDispatch({
|
|
|
|
owner: 'bitwarden',
|
|
|
|
repo: 'devops',
|
|
|
|
workflow_id: 'deploy-k8s.yml',
|
|
|
|
ref: 'main',
|
|
|
|
inputs: {
|
|
|
|
environment: 'US-DEV Cloud',
|
|
|
|
tag: 'main'
|
|
|
|
}
|
|
|
|
})
|
2024-10-21 14:11:59 +02:00
|
|
|
|
2024-10-10 17:49:04 +02:00
|
|
|
trigger-ee-updates:
|
|
|
|
name: Trigger Ephemeral Environment updates
|
|
|
|
if: github.ref != 'refs/heads/main' && contains(github.event.pull_request.labels.*.name, 'ephemeral-environment')
|
|
|
|
runs-on: ubuntu-24.04
|
|
|
|
needs: build-docker
|
|
|
|
steps:
|
|
|
|
- name: Log in to Azure - CI subscription
|
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
|
|
|
with:
|
|
|
|
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }}
|
|
|
|
|
|
|
|
- name: Retrieve GitHub PAT secrets
|
|
|
|
id: retrieve-secret-pat
|
|
|
|
uses: bitwarden/gh-actions/get-keyvault-secrets@main
|
|
|
|
with:
|
|
|
|
keyvault: "bitwarden-ci"
|
|
|
|
secrets: "github-pat-bitwarden-devops-bot-repo-scope"
|
|
|
|
|
|
|
|
- name: Trigger Ephemeral Environment update
|
|
|
|
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
|
|
|
with:
|
|
|
|
github-token: ${{ steps.retrieve-secret-pat.outputs.github-pat-bitwarden-devops-bot-repo-scope }}
|
|
|
|
script: |
|
|
|
|
await github.rest.actions.createWorkflowDispatch({
|
|
|
|
owner: 'bitwarden',
|
|
|
|
repo: 'devops',
|
|
|
|
workflow_id: '_update_ephemeral_tags.yml',
|
|
|
|
ref: 'main',
|
|
|
|
inputs: {
|
2024-10-22 18:29:57 +02:00
|
|
|
ephemeral_env_branch: process.env.GITHUB_HEAD_REF
|
2024-10-10 17:49:04 +02:00
|
|
|
}
|
|
|
|
})
|
2023-12-19 18:05:02 +01:00
|
|
|
|
2021-10-13 21:50:40 +02:00
|
|
|
check-failures:
|
|
|
|
name: Check for failures
|
|
|
|
if: always()
|
2022-11-18 20:39:01 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2021-10-13 21:50:40 +02:00
|
|
|
needs:
|
2022-03-14 14:31:03 +01:00
|
|
|
- lint
|
2021-10-13 21:50:40 +02:00
|
|
|
- build-artifacts
|
|
|
|
- build-docker
|
|
|
|
- upload
|
2023-03-07 14:10:34 +01:00
|
|
|
- build-mssqlmigratorutility
|
2023-06-27 19:18:51 +02:00
|
|
|
- self-host-build
|
2023-12-19 18:05:02 +01:00
|
|
|
- trigger-k8s-deploy
|
2021-10-13 21:50:40 +02:00
|
|
|
steps:
|
|
|
|
- name: Check if any job failed
|
2021-11-08 19:39:32 +01:00
|
|
|
if: |
|
2024-03-05 21:14:50 +01:00
|
|
|
(github.ref == 'refs/heads/main'
|
2021-11-08 19:39:32 +01:00
|
|
|
|| github.ref == 'refs/heads/rc'
|
2024-03-05 21:14:50 +01:00
|
|
|
|| github.ref == 'refs/heads/hotfix-rc')
|
|
|
|
&& contains(needs.*.result, 'failure')
|
|
|
|
run: exit 1
|
2021-10-13 21:50:40 +02:00
|
|
|
|
2024-01-23 19:24:52 +01:00
|
|
|
- name: Log in to Azure - CI subscription
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0
|
2021-10-13 21:50:40 +02:00
|
|
|
if: failure()
|
|
|
|
with:
|
2023-04-17 19:03:32 +02:00
|
|
|
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }}
|
2021-10-13 21:50:40 +02:00
|
|
|
|
2022-10-04 20:23:08 +02:00
|
|
|
- name: Retrieve secrets
|
2021-10-13 21:50:40 +02:00
|
|
|
id: retrieve-secrets
|
2023-11-08 19:08:15 +01:00
|
|
|
uses: bitwarden/gh-actions/get-keyvault-secrets@main
|
2021-10-13 21:50:40 +02:00
|
|
|
if: failure()
|
2022-10-04 20:23:08 +02:00
|
|
|
with:
|
2023-04-17 15:06:57 +02:00
|
|
|
keyvault: "bitwarden-ci"
|
2022-10-04 20:23:08 +02:00
|
|
|
secrets: "devops-alerts-slack-webhook-url"
|
2021-10-13 21:50:40 +02:00
|
|
|
|
|
|
|
- name: Notify Slack on failure
|
2024-07-10 21:47:20 +02:00
|
|
|
uses: act10ns/slack@44541246747a30eb3102d87f7a4cc5471b0ffb7d # v2.1.0
|
2021-10-13 21:50:40 +02:00
|
|
|
if: failure()
|
|
|
|
env:
|
|
|
|
SLACK_WEBHOOK_URL: ${{ steps.retrieve-secrets.outputs.devops-alerts-slack-webhook-url }}
|
|
|
|
with:
|
|
|
|
status: ${{ job.status }}
|