This repository has been archived by the owner on May 25, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 909
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: use open sauced semantic release configuration (#1120)
* feat: add semantic-release configuration dependencies * feat: remove stardard-version artifacts and update semantic-release * feat: added minimalistic docker build * feat: add under-engineered release workflow closes #1107 * fix: add missing commitizen conventional commit defaults * fix: correct static distribution github release path * docs: simplify workflows by code splitting docs
- Loading branch information
Showing
38 changed files
with
34,495 additions
and
55,622 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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"path": "./node_modules/cz-conventional-changelog" | ||
} |
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
23 changes: 3 additions & 20 deletions
23
.github/workflows/pr-audit-target.yml → .github/workflows/compliance.yml
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
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,175 @@ | ||
name: "Release" | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
docker: | ||
name: Build container | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "☁️ checkout repository" | ||
uses: actions/checkout@v2 | ||
|
||
- name: "🔧 setup buildx" | ||
uses: docker/setup-buildx-action@v1 | ||
|
||
- name: "📦 docker build" | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: . | ||
tags: ${{ github.repository }}:latest | ||
outputs: type=docker,dest=/tmp/docker.tar | ||
push: false | ||
|
||
- name: "📂 docker artifacts" | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: docker | ||
path: /tmp/docker.tar | ||
|
||
build: | ||
name: Build application | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "☁️ checkout repository" | ||
uses: actions/checkout@v2 | ||
|
||
- name: "🔧 setup node" | ||
uses: actions/setup-node@v2.1.5 | ||
with: | ||
node-version: 16 | ||
|
||
- name: "🔧 setup cache" | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-node-${{ hashFiles('**/npm-shrinkwrap.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-node- | ||
- name: "🔧 install npm@7" | ||
run: npm i -g npm@7 | ||
|
||
- name: "📦 install dependencies" | ||
run: npm ci | ||
|
||
- name: "🚀 static app" | ||
run: npm run build | ||
|
||
- name: "📂 production artifacts" | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: build | ||
path: build | ||
|
||
lint: | ||
name: Code standards | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "☁️ checkout repository" | ||
uses: actions/checkout@v2 | ||
|
||
- name: "🔧 setup node" | ||
uses: actions/setup-node@v2.1.5 | ||
with: | ||
node-version: 16 | ||
|
||
- name: "🔧 setup cache" | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-node-${{ hashFiles('**/npm-shrinkwrap.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-node- | ||
- name: "🔧 install npm@7" | ||
run: npm i -g npm@7 | ||
|
||
- name: "📦 install dependencies" | ||
run: npm ci | ||
|
||
- name: "🔍 lint code" | ||
run: npm run lint | ||
|
||
release: | ||
environment: | ||
name: production | ||
url: https://github.com/${{ github.repository }}/releases/tag/v${{ steps.release.outputs.version }} | ||
name: Semantic release | ||
needs: | ||
- docker | ||
- build | ||
- lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "☁️ checkout repository" | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: "🔧 setup node" | ||
uses: actions/setup-node@v2.1.5 | ||
with: | ||
node-version: 16 | ||
|
||
- name: "🔧 setup cache" | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-node-${{ hashFiles('**/npm-shrinkwrap.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-node- | ||
- name: "🔧 install npm@7" | ||
run: npm i -g npm@7 | ||
|
||
- name: "📦 install dependencies" | ||
run: npm ci | ||
|
||
- name: "📂 download docker artifacts" | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: docker | ||
path: /tmp | ||
|
||
- name: "📦 load tag" | ||
run: | | ||
docker load --input /tmp/docker.tar | ||
docker image ls -a | ||
- name: "📂 download build artifacts" | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: build | ||
path: /tmp/build | ||
|
||
- name: "🚀 release" | ||
id: release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
REPO_OWNER: ${{ github.repository_owner }} | ||
GIT_AUTHOR_NAME: ${{ github.event.commits[0].author.username }} | ||
GIT_AUTHOR_EMAIL: ${{ github.event.commits[0].author.email }} | ||
GIT_COMMITTER_NAME: ${{ secrets.GIT_COMMITTER_NAME }} | ||
GIT_COMMITTER_EMAIL: ${{ secrets.GIT_COMMITTER_EMAIL }} | ||
run: | | ||
cp -R /tmp/build ./build | ||
npx semantic-release | ||
echo "::set-output name=version::$(cat package.json | jq -r '.version')" | ||
cleanup: | ||
name: Cleanup actions | ||
needs: | ||
- release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "♻️ remove build artifacts" | ||
uses: geekyeggo/delete-artifact@v1 | ||
with: | ||
name: | | ||
build | ||
docs | ||
docker |
10 changes: 6 additions & 4 deletions
10
.github/workflows/assign-yourself.yml → .github/workflows/triage.yml
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,16 +1,18 @@ | ||
name: Assign | ||
name: "Triage" | ||
|
||
on: | ||
issue_comment: | ||
types: [created, edited] | ||
types: | ||
- created | ||
- edited | ||
|
||
jobs: | ||
one: | ||
runs-on: ubuntu-latest | ||
steps: | ||
# .take in an issue comment. | ||
- name: take an issue | ||
uses: bdougie/take-action@main | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
with: | ||
message: Thanks for taking this on! If you have not already, join the conversation in our [Discord](https://discord.gg/U2peSNf23P) | ||
message: Thanks for taking this on! If you have not already, join the conversation in our [Discord](https://discord.gg/U2peSNf23P) |
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,26 @@ | ||
FROM node:16-alpine as development | ||
|
||
WORKDIR /app | ||
|
||
COPY package.json ./ | ||
COPY npm-shrinkwrap.json ./ | ||
COPY .npmrc ./ | ||
COPY .babelrc ./ | ||
COPY .eslintrc.yml ./ | ||
|
||
RUN npm ci | ||
|
||
COPY config ./config | ||
COPY scripts ./scripts | ||
COPY public ./public | ||
COPY src ./src | ||
|
||
CMD [ "npm", "start"] | ||
|
||
FROM development as builder | ||
|
||
RUN npm run build | ||
|
||
FROM nginx:1.21-alpine as production | ||
|
||
COPY --from=builder /app/build /usr/share/nginx/html |
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.