Skip to content
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
16 changes: 8 additions & 8 deletions .github/workflows/build-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,25 +46,25 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v6
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
submodules: recursive

- name: Login to GitHub container registry
uses: docker/login-action@v4
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4

- name: Sanitize branch name
run: echo "SAFE_REF=${GITHUB_REF_NAME//\//-}" >> $GITHUB_ENV

- name: Build container
uses: docker/build-push-action@v7
uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f # v7
with:
context: .
platforms: linux/${{ matrix.cpu }}
Expand All @@ -77,7 +77,7 @@ jobs:
cache-to: type=registry,mode=max,ref=${{ env.GHCR_REPO }}:cache-${{ matrix.tag }}-${{ env.SAFE_REF }}

- name: Scan image with Trivy
uses: aquasecurity/trivy-action@v0.36.0
uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
env:
TRIVY_SHOW_SUPPRESSED: 1
TRIVY_IGNOREFILE: "./.trivyignore.yaml"
Expand All @@ -101,19 +101,19 @@ jobs:

steps:
- name: Install Cosign
uses: sigstore/cosign-installer@v4.1.0
uses: sigstore/cosign-installer@cad07c2e89fa2edd6e2d7bab4c1aa38e53f76003 # v4.1.1

- name: Docker meta
id: meta
uses: docker/metadata-action@v6
uses: docker/metadata-action@030e881283bb7a6894de51c315a6bfe6a94e05cf # v6
with:
images: |
${{ env.GHCR_REPO }}
flavor: ${{ inputs.flavor }}
tags: ${{ inputs.tags }}

- name: Login to GitHub container registry
uses: docker/login-action@v4
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4
with:
registry: ghcr.io
username: ${{ github.actor }}
Expand Down
32 changes: 16 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,17 @@ name: Continuous integration
on:
push:
branches:
- main
- dev
- "release/**"
- "stable/**"
paths-ignore:
- "*.md"
- "LICENSE"
pull_request:
branches:
- main
- dev
- "release/**"
- "stable/**"
paths-ignore:
- "*.md"
- "LICENSE"
Expand All @@ -37,7 +37,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v6
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
submodules: recursive

Expand All @@ -47,7 +47,7 @@ jobs:
echo "$GITHUB_WORKSPACE/.cargo/bin" >> $GITHUB_PATH

- name: Cache cargo registry
uses: actions/cache@v4
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
with:
path: |
${{ env.CARGO_HOME }}/registry/index
Expand All @@ -57,10 +57,10 @@ jobs:
restore-keys: cargo-registry-

- name: Run sccache-cache
uses: mozilla-actions/sccache-action@v0.0.9
uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad # v0.0.9

- name: Scan code with Trivy
uses: aquasecurity/trivy-action@v0.36.0
uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
env:
TRIVY_SHOW_SUPPRESSED: 1
TRIVY_IGNOREFILE: "./.trivyignore.yaml"
Expand All @@ -86,7 +86,7 @@ jobs:
cargo clippy --all-targets --all-features -- -D warnings

- name: Install cargo-deny
uses: taiki-e/install-action@v2
uses: taiki-e/install-action@3235f8901fd37ffed0052b276cec25a362fb82e9 # v2
with:
tool: cargo-deny

Expand Down Expand Up @@ -115,7 +115,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v6
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
submodules: recursive

Expand All @@ -125,7 +125,7 @@ jobs:
echo "$GITHUB_WORKSPACE/.cargo/bin" >> $GITHUB_PATH

- name: Cache cargo registry
uses: actions/cache@v4
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
with:
path: |
${{ env.CARGO_HOME }}/registry/index
Expand All @@ -135,13 +135,13 @@ jobs:
restore-keys: cargo-registry-

- name: Run sccache-cache
uses: mozilla-actions/sccache-action@v0.0.9
uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad # v0.0.9

- name: Install protoc
run: apt-get update && apt-get -y install protobuf-compiler

- name: Install cargo-nextest
uses: taiki-e/install-action@v2
uses: taiki-e/install-action@3235f8901fd37ffed0052b276cec25a362fb82e9 # v2
with:
tool: cargo-nextest

Expand All @@ -159,7 +159,7 @@ jobs:
run: sccache --show-stats

- name: Upload test archive
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: nextest-archive
path: nextest-archive.tar.zst
Expand Down Expand Up @@ -205,18 +205,18 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v6
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
submodules: recursive
fetch-depth: 1

- name: Download test archive
uses: actions/download-artifact@v4
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4
with:
name: nextest-archive

- name: Install cargo-nextest
uses: taiki-e/install-action@v2
uses: taiki-e/install-action@3235f8901fd37ffed0052b276cec25a362fb82e9 # v2
with:
tool: cargo-nextest

Expand All @@ -233,7 +233,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Delete test archive artifact
uses: actions/github-script@v7
uses: actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7
with:
script: |
const artifacts = await github.rest.actions.listWorkflowRunArtifacts({
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/current.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ permissions:
on:
push:
branches:
- main
- dev
- "release/**"
- "stable/**"
paths-ignore:
- "*.md"
- "LICENSE"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dev-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ jobs:
- name: Add SHORT_SHA env variable
run: echo "SHORT_SHA=`echo ${GITHUB_SHA} | cut -c1-7`" >> $GITHUB_ENV
- name: Deploy new image version
uses: actions-hub/kubectl@v1.34.3
uses: actions-hub/kubectl@2639090a038d46a3b9b98b220ae0837676ded8b7 # v1.34.3
with:
args: --namespace defguard-dev set image deployment/defguard defguard=ghcr.io/defguard/defguard:sha-${{ env.SHORT_SHA }}
48 changes: 24 additions & 24 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
shard: [1, 2, 3, 4, 5, 6, 7, 8]

steps:
- uses: actions/checkout@v6
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4

- name: Login to GitHub container registry
uses: docker/login-action@v4
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4
with:
registry: ghcr.io
username: ${{ github.actor }}
Expand All @@ -42,13 +42,13 @@ jobs:
echo "E2E tests will run on IMAGE_TAG=$IMAGE_TAG"

- name: Set up Node
uses: actions/setup-node@v6
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
with:
node-version-file: "./e2e/.nvmrc"

- name: Install pnpm
id: pnpm-install
uses: pnpm/action-setup@v4
uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6
with:
# FIXME: temporarily pinned because of https://github.com/pnpm/pnpm/pull/9959
version: 10.17
Expand All @@ -60,7 +60,7 @@ jobs:
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@v5
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
Expand All @@ -77,7 +77,7 @@ jobs:

- name: Cache Playwright browsers
id: playwright-cache
uses: actions/cache@v5
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
with:
path: ~/.cache/ms-playwright
key: ${{ runner.os }}-playwright-${{ hashFiles('e2e/pnpm-lock.yaml') }}
Expand Down Expand Up @@ -105,7 +105,7 @@ jobs:
if: always()
run: docker compose --file './docker-compose.e2e.yaml' down

- uses: actions/upload-artifact@v7
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
if: failure()
with:
name: playwright-report-shard-${{ matrix.shard }}
Expand All @@ -119,12 +119,12 @@ jobs:
instance-size:medium

steps:
- uses: actions/checkout@v6
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4

- name: Login to GitHub container registry
uses: docker/login-action@v4
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4
with:
registry: ghcr.io
username: ${{ github.actor }}
Expand All @@ -141,12 +141,12 @@ jobs:
echo "IMAGE_TAG=$IMAGE_TAG" >> $GITHUB_ENV

- name: Set up Node
uses: actions/setup-node@v6
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
with:
node-version-file: "./e2e/.nvmrc"

- name: Install pnpm
uses: pnpm/action-setup@v4
uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6
with:
# FIXME: temporarily pinned because of https://github.com/pnpm/pnpm/pull/9959
version: 10.17
Expand All @@ -158,7 +158,7 @@ jobs:
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@v5
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
Expand All @@ -175,7 +175,7 @@ jobs:

- name: Cache Playwright browsers
id: playwright-cache
uses: actions/cache@v5
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
with:
path: ~/.cache/ms-playwright
key: ${{ runner.os }}-playwright-${{ hashFiles('e2e/pnpm-lock.yaml') }}
Expand All @@ -201,7 +201,7 @@ jobs:
if: always()
run: docker compose --file './docker-compose.e2e.yaml' down

- uses: actions/upload-artifact@v7
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
if: failure()
with:
name: playwright-report-migration-wizard
Expand All @@ -215,12 +215,12 @@ jobs:
instance-size:medium

steps:
- uses: actions/checkout@v6
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4

- name: Login to GitHub container registry
uses: docker/login-action@v4
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4
with:
registry: ghcr.io
username: ${{ github.actor }}
Expand All @@ -237,12 +237,12 @@ jobs:
echo "IMAGE_TAG=$IMAGE_TAG" >> $GITHUB_ENV

- name: Set up Node
uses: actions/setup-node@v6
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
with:
node-version-file: "./e2e/.nvmrc"

- name: Install pnpm
uses: pnpm/action-setup@v4
uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6
with:
# FIXME: temporarily pinned because of https://github.com/pnpm/pnpm/pull/9959
version: 10.17
Expand All @@ -254,7 +254,7 @@ jobs:
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@v5
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
Expand All @@ -271,7 +271,7 @@ jobs:

- name: Cache Playwright browsers
id: playwright-cache
uses: actions/cache@v5
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5
with:
path: ~/.cache/ms-playwright
key: ${{ runner.os }}-playwright-${{ hashFiles('e2e/pnpm-lock.yaml') }}
Expand All @@ -297,7 +297,7 @@ jobs:
if: always()
run: docker compose --file './docker-compose.e2e-auto-adoption.yaml' down

- uses: actions/upload-artifact@v7
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
if: failure()
with:
name: playwright-report-auto-adoption-wizard
Expand Down
Loading
Loading