Skip to content

Commit

Permalink
update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
flarco committed Sep 22, 2024
1 parent 1192eb8 commit a1cc616
Show file tree
Hide file tree
Showing 2 changed files with 67 additions and 18 deletions.
34 changes: 28 additions & 6 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,7 @@ on:
types: [build-release]

env:
GITHUB_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.DO_SPACE_ACCESS_KEY}}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DO_SPACE_SECRET_KEY}}
PLAUSIBLE_URL: ${{ secrets.PLAUSIBLE_URL }}
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
GOPRIVATE: github.com/slingdata-io/*
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}

jobs:
build:
Expand Down Expand Up @@ -99,6 +93,13 @@ jobs:
go-version: "1.22"
cache: false

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Configure private token & Prep
run: bash scripts/ci/prep.mac.sh

Expand Down Expand Up @@ -129,6 +130,13 @@ jobs:
with:
go-version: "1.22"
cache: true

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Configure Pagefile
uses: al-cheb/[email protected]
Expand Down Expand Up @@ -171,6 +179,13 @@ jobs:
with:
go-version: "1.22"
cache: false

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Login docker
run: |
Expand Down Expand Up @@ -218,6 +233,13 @@ jobs:
with:
go-version: "1.22"
cache: false

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Login docker
run: |
Expand Down
51 changes: 39 additions & 12 deletions .github/workflows/test-docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,15 @@ jobs:
go-version: "1.22"
cache: false

- name: Configure private token
run: |
git config --global url."https://${GITHUB_TOKEN}:[email protected]/".insteadOf "https://github.com/"
- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Configure private token & Prep
run: bash scripts/ci/prep.mac.sh

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3
Expand Down Expand Up @@ -85,6 +91,13 @@ jobs:
with:
go-version: "1.22"
cache: true

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Configure Pagefile
uses: al-cheb/[email protected]
Expand All @@ -93,10 +106,12 @@ jobs:
maximum-size: 16GB
disk-root: "C:"

- name: Configure private token
- name: Configure private token & Prep
shell: pwsh
run: |
$url = ("https://" + $env:GITHUB_TOKEN + ":[email protected]/")
git config --global url."$url".insteadOf "https://github.com/"
$ErrorActionPreference = "Stop"
.\scripts\ci\prep.win.ps1
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3
Expand Down Expand Up @@ -125,14 +140,20 @@ jobs:
with:
go-version: "1.22"
cache: false

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Login docker
run: |
echo "$DOCKER_PASSWORD" | docker login -u slingdata --password-stdin
- name: Configure private token
run: |
git config --global url."https://${GITHUB_TOKEN}:[email protected]/".insteadOf "https://github.com/"
- name: Configure private token & Prep
run: bash scripts/ci/prep.linux.sh

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3
Expand Down Expand Up @@ -161,14 +182,20 @@ jobs:
with:
go-version: "1.22"
cache: false

- name: Load Secrets
uses: flarco/infisical-action@v2
with:
version: 0.28.1
client_id: ${{ secrets.INFISICAL_CLIENT_ID }}
client_secret: ${{ secrets.INFISICAL_CLIENT_SECRET }}

- name: Login docker
run: |
echo "$DOCKER_PASSWORD" | docker login -u slingdata --password-stdin
- name: Configure private token
run: |
git config --global url."https://${GITHUB_TOKEN}:[email protected]/".insteadOf "https://github.com/"
- name: Configure private token & Prep
run: bash scripts/ci/prep.linux.sh

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3
Expand Down

0 comments on commit a1cc616

Please sign in to comment.