Skip to content

Next.js - Create App - Stable #228

Next.js - Create App - Stable

Next.js - Create App - Stable #228

name: Next.js - Create App - Stable
on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
container:
image: bitsrc/stable:latest
env:
HOME: /home/bituser
steps:
- name: Initialize a new workspace
run: |
bit
bvm
bvm upgrade
bit init my-nextjs-workspace --default-scope my-org.my-scope --log error
- name: Create a Next.js app component
run: |
cd my-nextjs-workspace
bit create nextjs apps/my-nextjs-app --aspect frontend.nextjs/nextjs-env --log error
- name: Show components, envs and status
run: |
cd my-nextjs-workspace
bit list --log error
bit envs --log error
bit status --log error
- name: Compile, lint, test components
run: |
cd my-nextjs-workspace
bit compile --log error
bit lint --log error
bit test --log error
- name: Run Next.js app component
run: |
cd my-nextjs-workspace
bit run my-nextjs-app --log error &
checkserver http://localhost:3000
- name: Tag components
run: |
cd my-nextjs-workspace
bit tag --message "initial tag" --log error
- name: Create a local scope
run: |
barescope my-org.my-scope my-nextjs-workspace
- name: Export components
run: |
cd my-nextjs-workspace
bit export --log error
continue-on-error: false