Skip to content

Trigger from Local

Trigger from Local #36

Workflow file for this run

name: Release
on:
repository_dispatch:
workflow_dispatch:
workflow_run:
workflows: ["Build"]
branches: [main]
types: [completed]
jobs:
install-packages:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setups
- name: Install packages
run: yarn install
build-english:
needs: install-packages
runs-on: ubuntu-latest
env:
NOTION_TOKEN: ${{ secrets.NOTION_TOKEN }}
ROTION_INCREMENTAL_CACHE: true
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setups
- name: Run next build for english
run: yarn build
env:
NEXT_PUBLIC_LANG: en
- name: Save html
uses: actions/upload-artifact@v4
with:
name: english-out
path: out
deploy-english:
needs: build-english
runs-on: ubuntu-latest
steps:
- name: Download html
uses: actions/download-artifact@v4
with:
name: english-out
path: out
- name: Deploy to prod.cognanous.com by FTP
uses: SamKirkland/[email protected]
with:
server: ${{ secrets.FTP_HOST }}
username: ${{ secrets.FTP_USER_PROD_EN }}
password: ${{ secrets.FTP_PASS_PROD_EN }}
local-dir: ./out/
exclude: ogimages/*-ja-*.png
build-japanese:
needs: build-english
runs-on: ubuntu-latest
env:
NOTION_TOKEN: ${{ secrets.NOTION_TOKEN }}
ROTION_INCREMENTAL_CACHE: true
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setups
- name: Run next build for japanese
run: yarn build
env:
NEXT_PUBLIC_LANG: ja
- name: Save html
uses: actions/upload-artifact@v4
with:
name: japanese-out
path: out
deploy-japanese:
needs: build-japanese
runs-on: ubuntu-latest
steps:
- name: Download html
uses: actions/download-artifact@v4
with:
name: japanese-out
path: out
- name: Deploy to prod.cognano.co.jp by FTP
uses: SamKirkland/[email protected]
with:
server: ${{ secrets.FTP_HOST }}
username: ${{ secrets.FTP_USER_PROD_JA }}
password: ${{ secrets.FTP_PASS_PROD_JA }}
local-dir: ./out/
exclude: ogimages/*-en-*.png