feat: migrate settings #7
Workflow file for this run
This file contains 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: frontend | |
on: | |
push: | |
paths: | |
- "apps/frontend/**" | |
branches: | |
- "**" | |
pull_request: | |
paths: | |
- "apps/frontend/**" | |
branches: | |
- "**" | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Use Node.js 20 | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: Install Pnpm | |
uses: pnpm/action-setup@v4 | |
with: | |
version: 9.14.2 | |
- name: Install dependencies | |
run: pnpm install | |
- name: Pre compilation | |
run: pnpm run build --filter frontend | |
# テスト成功時はこちらのステップが実行される | |
- name: Slack Notification on Success at Testing Stage | |
if: success() | |
uses: rtCamp/action-slack-notify@v2 | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOKS }} | |
SLACK_CHANNEL: github-actions | |
SLACK_TITLE: Test Success | |
SLACK_COLOR: good | |
SLACK_FOOTER: 'Powered by Yancey Inc. and its affiliates.' | |
# テスト失敗時はこちらのステップが実行される | |
- name: Slack Notification on Failure at Testing Stage | |
uses: rtCamp/action-slack-notify@v2 | |
if: failure() | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOKS }} | |
SLACK_CHANNEL: github-actions | |
SLACK_TITLE: Test Failure | |
SLACK_COLOR: danger | |
SLACK_FOOTER: 'Powered by Yancey Inc. and its affiliates.' | |
deployment: | |
runs-on: ubuntu-latest | |
continue-on-error: true | |
needs: test | |
if: github.ref == 'refs/heads/master' | |
steps: | |
- name: Deploy to server | |
uses: appleboy/ssh-action@v0.1.4 | |
with: | |
host: ${{ secrets.HOST }} | |
username: ${{ secrets.USERNAME }} | |
password: ${{ secrets.PASSWORD }} | |
script: sh ./@beg-monorepo-frontend-deploy.sh | |
# テスト成功時はこちらのステップが実行される | |
- name: Slack Notification on Success at Deployment Stage | |
if: success() | |
uses: rtCamp/action-slack-notify@v2 | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOKS }} | |
SLACK_CHANNEL: github-actions | |
SLACK_TITLE: Deploy Success | |
SLACK_COLOR: good | |
SLACK_FOOTER: 'Powered by Yancey Inc. and its affiliates.' | |
# テスト失敗時はこちらのステップが実行される | |
- name: Slack Notification on Failure at Deployment Stage | |
uses: rtCamp/action-slack-notify@v2 | |
if: failure() | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOKS }} | |
SLACK_CHANNEL: github-actions | |
SLACK_TITLE: Deploy Failure | |
SLACK_COLOR: danger | |
SLACK_FOOTER: 'Powered by Yancey Inc. and its affiliates.' |