Skip to content

Deploy to IPFS as part of the CI pipeline #927

Deploy to IPFS as part of the CI pipeline

Deploy to IPFS as part of the CI pipeline #927

Workflow file for this run

name: Web Deploy to dev/staging
on:
pull_request:
push:
branches:
- dev
- main
paths:
- apps/web/**
- packages/**
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
deploy:
runs-on: ubuntu-latest
permissions:
pull-requests: write
id-token: write
name: Deploy to dev/staging
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/yarn
- uses: ./.github/actions/build
with:
secrets: ${{ toJSON(secrets) }}
# if: startsWith(github.ref, 'refs/heads/main')
# Script to upload to IPFS
- name: Upload to IPFS
uses: aquiladev/ipfs-action@v0.2.1
with:
path: apps/web
service: pinata
pinataKey: ${{ secrets.PINATA_API_KEY }}
pinataSecret: ${{ secrets.PINATA_SECRET_KEY }}
- name: Output IPFS CID
run: |
echo "Deployed to IPFS: ${{ steps.upload.outputs.Hash }}"
echo "Gateway link: https://ipfs.io/ipfs/${{ steps.upload.outputs.Hash }}"