-
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.
build: fix ci/cd canary action fix: missing type Add build args to canary workflow build(gh-actions): update gh action template versions to latest build(cd): argo cd should target git tags build: drop canary channels, use v0.*.* build(ci): handle no semver tags case Reset version # back to 0 Add release-it Progress Test Test Test Fixes v0.1.1 Reset version number, use minor release by default Test Test Drop github from CI Test Progress Test Cleanup Add more scripts Updates Progress Git pull before anything chore: use auto-changelog Use conventional commits Infer next version PR Create PR Do not create new branch
- Loading branch information
Showing
20 changed files
with
2,265 additions
and
59 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,99 @@ | ||
name: Release | ||
on: | ||
workflow_dispatch: | ||
jobs: | ||
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
packages: write | ||
pull-requests: write | ||
id-token: write | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Login to git | ||
run: | | ||
git pull | ||
git config user.name "${{ github.actor }}" | ||
git config user.email "${{ github.actor }}@users.noreply.github.com" | ||
- name: Install pnpm | ||
uses: pnpm/action-setup@v4 | ||
with: | ||
run_install: false | ||
|
||
- name: Install Node.js 20 | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version-file: 'package.json' | ||
architecture: 'x64' | ||
cache: 'pnpm' | ||
|
||
- name: Install dependencies | ||
run: pnpm install | ||
|
||
- name: Determine next version | ||
id: next-version | ||
run: | | ||
NEW_VERSION=$(pnpm release --ci --release-version | tail -n1) | ||
echo "new_version=$NEW_VERSION" >> $GITHUB_OUTPUT | ||
# - name: Set up QEMU | ||
# uses: docker/setup-qemu-action@v3 | ||
# | ||
# - name: Setup Docker Buildx | ||
# uses: docker/setup-buildx-action@v3 | ||
# | ||
# - name: Login to ghcr.io | ||
# uses: docker/login-action@v3 | ||
# with: | ||
# registry: ghcr.io | ||
# username: ${{ github.actor }} | ||
# password: ${{ secrets.GITHUB_TOKEN }} | ||
# | ||
# - name: Build @avelin/app | ||
# uses: docker/build-push-action@v6 | ||
# with: | ||
# context: . | ||
# file: ./apps/web/Dockerfile | ||
# push: true | ||
# tags: ghcr.io/avelinapp/web:latest,ghcr.io/avelinapp/web:${{ steps.next_version.outputs.new_version }},ghcr.io/avelinapp/web:v${{ steps.next_version.outputs.new_version }} | ||
# build-args: NEXT_PUBLIC_APP_URL=https://avelin.app,NEXT_PUBLIC_API_URL=https://api.avelin.app,NEXT_PUBLIC_SYNC_URL=wss://sync.avelin.app | ||
# platforms: linux/amd64 | ||
# | ||
# - name: Build @avelin/api | ||
# uses: docker/build-push-action@v6 | ||
# with: | ||
# context: . | ||
# file: ./apps/api/Dockerfile | ||
# push: true | ||
# tags: ghcr.io/avelinapp/api:latest,ghcr.io/avelinapp/api:${{ steps.next_version.outputs.new_version }},ghcr.io/avelinapp/api:v${{ steps.next_version.outputs.new_version }} | ||
# platforms: linux/amd64 | ||
# | ||
# - name: Build @avelin/sync | ||
# uses: docker/build-push-action@v6 | ||
# with: | ||
# context: . | ||
# file: ./apps/sync/Dockerfile | ||
# push: true | ||
# tags: ghcr.io/avelinapp/sync:latest,ghcr.io/avelinapp/sync:${{ steps.next_version.outputs.new_version }},ghcr.io/avelinapp/sync:v${{ steps.next_version.outputs.new_version }} | ||
# platforms: linux/amd64 | ||
|
||
- name: Bump version | ||
run: | | ||
pnpm release --ci | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Create release PR | ||
uses: peter-evans/create-pull-request@v7 | ||
with: | ||
title: 'v${{ steps.next_version.outputs.new_version }}' | ||
assignees: 'bazzadev' |
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,38 @@ | ||
{ | ||
"$schema": "https://unpkg.com/release-it/schema/release-it.json", | ||
"plugins": { | ||
"@release-it/conventional-changelog": { | ||
"infile": "CHANGELOG.md", | ||
"preset": { | ||
"name": "conventionalcommits", | ||
"types": [ | ||
{ | ||
"type": "feat", | ||
"section": "Features" | ||
}, | ||
{ | ||
"type": "fix", | ||
"section": "Fixes" | ||
}, | ||
{} | ||
] | ||
} | ||
} | ||
}, | ||
"git": { | ||
"commitMessage": "v${version}", | ||
"tagName": "v${version}", | ||
"push": false, | ||
"commit": false, | ||
"requireCleanWorkingDir": false, | ||
"changelog": "pnpm dlx auto-changelog --stdout --commit-limit false --unreleased --template https://raw.githubusercontent.com/release-it/release-it/main/templates/changelog-compact.hbs" | ||
}, | ||
"github": { | ||
"release": true, | ||
"releaseName": "v${version}", | ||
"draft": true | ||
}, | ||
"hooks": { | ||
"after:bump": "node scripts/sync-versions.js && pnpm dlx auto-changelog -p" | ||
} | ||
} |
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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
import { createClient } from '@avelin/api/client' | ||
|
||
if (!process.env.NEXT_PUBLIC_API_URL) { | ||
throw new Error('API_URL is not set') | ||
throw new Error('NEXT_PUBLIC_API_URL is not set') | ||
} | ||
|
||
export const api = createClient(process.env.NEXT_PUBLIC_API_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
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,20 @@ | ||
apiVersion: argoproj.io/v1alpha1 | ||
kind: Application | ||
metadata: | ||
name: avelin | ||
namespace: argocd | ||
spec: | ||
project: default | ||
source: | ||
repoURL: 'https://github.com/avelinapp/avelin.git' | ||
targetRevision: '>=v0.0.0' | ||
path: 'deploy/k8s' | ||
destination: | ||
server: 'https://kubernetes.default.svc' | ||
namespace: avelin | ||
syncPolicy: | ||
automated: | ||
prune: true | ||
selfHeal: true | ||
syncOptions: | ||
- CreateNamespace=true |
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
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
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
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
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
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
Oops, something went wrong.