Skip to content

Commit

Permalink
👷 deploy to github pages
Browse files Browse the repository at this point in the history
  • Loading branch information
krmax44 committed Jan 13, 2025
1 parent 7b7c13b commit 324b9a2
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 0 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Deploy static content to Pages

on:
push:
branches: ['main']

workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: 'pages'
cancel-in-progress: true

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 22
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Write secret files
run: |
echo ${{ secrets.ENV }} > .env
echo ${{ secrets.SERVICE_ACCOUNT }} > service-account.json
- name: Build
run: pnpm run build
- name: Delete secrets
run: rm .env service-account.json
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: './dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
1 change: 1 addition & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import Icons from 'unplugin-icons/vite'

// https://astro.build/config
export default defineConfig({
base: '/real-o-mat/',
output: 'static',
integrations: [tailwind(), vue()],
vite: {
Expand Down

0 comments on commit 324b9a2

Please sign in to comment.