Merge pull request #841 from Adamant-im/fix/add-margin-top-to-exportk… #70
This file contains hidden or 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
name: PWA Testnet Workflow | |
on: | |
push: | |
branches: | |
- dev | |
- master | |
env: | |
SURGE_TOKEN: ${{ secrets.SURGE_TOKEN }} | |
PREVIEW_DOMAIN: ${{ github.ref_name == 'master' && 'https://msg-adamant-testnet.surge.sh' || 'https://dev-adamant-testnet.surge.sh' }} | |
CUSTOM_DOMAIN: ${{ github.ref_name == 'master' && 'http://msg-testnet.adamant.im' || 'http://dev-testnet.adamant.im' }} | |
jobs: | |
build-and-deploy-to-surge: | |
name: Build and Deploy with Testnet ADM nodes to surge | |
runs-on: ubuntu-latest | |
environment: testnet | |
steps: | |
- name: Checkout repository 🛎️ | |
uses: actions/checkout@v4 | |
- name: Setup Node version 🍀 | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20' | |
- name: Install dependencies ⚙️ | |
run: npm ci | |
- name: Build PWA 🛠️ | |
run: | | |
npm run schema:generate | |
npm run build:testnet | |
- name: Archive artifacts 📁 | |
uses: actions/upload-artifact@v4 | |
with: | |
path: dist | |
- name: Deploy to surge 🚀 | |
run: | | |
npm install --global surge | |
surge ./dist ${{ env.PREVIEW_DOMAIN }} --token ${{ secrets.SURGE_TOKEN }} | |
surge ./dist ${{ env.CUSTOM_DOMAIN }} --token ${{ secrets.SURGE_TOKEN }} |