mirror of
https://github.com/mroxso/zelo-news.git
synced 2026-04-08 22:46:57 +02:00
41 lines
1.0 KiB
YAML
41 lines
1.0 KiB
YAML
name: Deploy to Blossom
|
|
|
|
on:
|
|
# Runs on pushes targeting the default branch
|
|
push:
|
|
branches: ["main"]
|
|
# Allows you to run this workflow manually from the Actions tab
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
# Single deploy job
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "22"
|
|
cache: npm
|
|
|
|
- name: Install dependencies and build
|
|
run: |
|
|
npm install
|
|
npm run build
|
|
|
|
- name: Create deployment environment file
|
|
run: |
|
|
cat > .env.nostr-deploy.local << EOF
|
|
BASE_DOMAIN=${{ secrets.BASE_DOMAIN }}
|
|
BLOSSOM_SERVERS=${{ secrets.BLOSSOM_SERVERS }}
|
|
NOSTR_PRIVATE_KEY=${{ secrets.NOSTR_PRIVATE_KEY }}
|
|
NOSTR_PUBLIC_KEY=${{ secrets.NOSTR_PUBLIC_KEY }}
|
|
NOSTR_RELAYS=${{ secrets.NOSTR_RELAYS }}
|
|
EOF
|
|
|
|
- name: Upload to Blossom
|
|
run: |
|
|
npm run deploy |