-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: use packages and improved drift checking (#26)
- Loading branch information
1 parent
e085757
commit 37debbd
Showing
24 changed files
with
1,734 additions
and
1,616 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,7 @@ name: Drift check | |
on: | ||
schedule: | ||
- cron: '0 0 * * *' | ||
workflow_dispatch: | ||
|
||
jobs: | ||
check-for-changes: | ||
|
@@ -11,21 +12,37 @@ jobs: | |
- name: Checkout 🛎️ | ||
uses: actions/checkout@v3 | ||
|
||
- name: Setup Node LTS ✨ | ||
uses: actions/setup-nodejs@v3 | ||
- uses: pnpm/action-setup@v2 | ||
|
||
- name: Use Node LTS ✨ | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: lts/* | ||
cache: yarn | ||
cache: pnpm | ||
|
||
- name: Installing dependencies 📦️ | ||
run: yarn install | ||
- name: Install dependencies 📦️ | ||
run: pnpm install --frozen-lockfile | ||
|
||
- name: Applying infrastructure 🚀 | ||
uses: pulumi/actions@v4 | ||
id: pulumi | ||
env: | ||
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }} | ||
with: | ||
command: preview | ||
refresh: true | ||
stack-name: bjerk/prod | ||
expect-no-changes: true | ||
|
||
- uses: slackapi/[email protected] | ||
# if: failure() | ||
with: | ||
payload: | | ||
{ | ||
"repositoryUrl": "bjerkio/bot", | ||
"jobUrl": "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}", | ||
"message": "Issues detected", | ||
"details": "${{ steps.pulumi.outputs.output }}" | ||
} | ||
env: | ||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Pull Request | ||
on: | ||
pull_request: | ||
|
||
jobs: | ||
preview-changes: | ||
name: Preview changes | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout 🛎️ | ||
uses: actions/checkout@v3 | ||
|
||
- uses: pnpm/action-setup@v2 | ||
|
||
- name: Use Node LTS ✨ | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: lts/* | ||
cache: pnpm | ||
|
||
- name: Install dependencies 📦️ | ||
run: pnpm install --frozen-lockfile | ||
|
||
- name: Run Pulumi 🚀 | ||
uses: pulumi/actions@v4 | ||
env: | ||
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }} | ||
with: | ||
command: preview | ||
refresh: true | ||
stack-name: bjerk/prod | ||
comment-on-pr: true | ||
github-token: ${{ secrets.BJERKBOT_GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Push | ||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
apply-changes: | ||
name: Apply changes | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout 🛎️ | ||
uses: actions/checkout@v3 | ||
|
||
- uses: pnpm/action-setup@v2 | ||
|
||
- name: Use Node LTS ✨ | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: lts/* | ||
cache: pnpm | ||
|
||
- name: Install dependencies 📦️ | ||
run: pnpm install --frozen-lockfile | ||
|
||
- name: Run Pulumi 🚀 | ||
uses: pulumi/actions@v4 | ||
env: | ||
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }} | ||
with: | ||
command: up | ||
refresh: true | ||
stack-name: bjerk/prod | ||
|
||
todo-to-issue: | ||
name: Create issue from TODO comments | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout 🛎️ | ||
uses: actions/checkout@v3 | ||
|
||
- name: Create issue from TODO comments 📝 | ||
uses: derjuulsn/todo-issue@main | ||
with: | ||
excludePattern: '^(node_modules/)' | ||
label: needs-refinement | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.BJERKIO_GITHUB_TOKEN }} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -102,3 +102,4 @@ dist | |
|
||
# TernJS port file | ||
.tern-port | ||
stack*.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
config: | ||
bjerk-bot:bjerkbot-github-token: | ||
secure: AAABAA9O48OAPfAGncxn53I4/Xi3byjISs4i7D1AEm2cFZm5FmTDZjKJPRplea7T1+i0/DPk9lcM15Q9D0ttK1TvZXcmia8x | ||
bjerk-bot:repositories-with-github-token: | ||
- repo: taksnor/infra | ||
- repo: taksnor/workflows | ||
bjerkio:org-wide-npm-expires-at: '2023-07-08' | ||
bjerkio:org-wide-npm-token: | ||
secure: AAABAKDA8LFLyp9CS4iTUfo/FJDd+DPtpG/+u4xKuA92TVr6L13Jp4Au1k/JJ/VQebb25H38/w2BDxZxf9qeNS2ZP9d5blku | ||
github:token: | ||
secure: AAABACBlKdGm/kuUYSToDvxLoNJu93dZp6qFZeN10MGie3zo+CxFENxQpvpLsW0an2Y6wOP29wfBPYm4fEIGAbtsBpb8DAZc | ||
github:token-expires-at: "2023-10-12T17:02:28.080Z" | ||
github:token-id: | ||
secure: AAABAGHYP1tlpnfEAZ8wZCtKTdtXQ7UexENZikcrOp3gGMKWa4+Kc3U= | ||
npm:token: | ||
secure: AAABANec3OTPD09nX1IICGMNdmglSEqjPt5ZHq3MOi9NNB5FUCMl+x205L1FafLyjQqB4fisiWbhNpKjm8d0lDoKrIVmrwbw | ||
npm:token-expires-at: "2023-10-12T17:03:05.892Z" |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.