I’m currently trying to deploy from the app directory to Github Action CI/CD.
But I keep getting a PageNotFoundError: Cannot find module for page: /
error, and I think the phenomenon that I can’t read the app path in my structure is happening. Below is the next.config.js file. Is there something I’m missing?
next.config.js
/** @type {import('next').NextConfig} */
const nextConfig = {
experimental: {
appDir: true,
},
};
module.exports = nextConfig;
nextjs.yml
Is there something I am doing wrong?
name: git push into another repo to deploy to vercel
on:
push:
branches: master
jobs:
build:
runs-on: ubuntu-latest
container: pandoc/latex
steps:
- uses: actions/checkout@v2
- name: Install mustache (to update the date)
run: apk add ruby && gem install mustache
- name: creates output
run: sh ./build.sh
- name: Pushes to another repository
id: push_directory
uses: cpina/github-action-push-to-another-repository@main
env:
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
with:
source-directory: 'output'
destination-github-username: [Seung-hwan285]
destination-repository-name: [Team-PODO-ODEEGO-FE
]
user-email: ${{ secrets.OFFICIAL_ACCOUNT_EMAIL }}
commit-message: ${{ github.event.commits[0].message }}
target-branch: main
- name: Test get variable exported by push-to-another-repository
run: echo $DESTINATION_CLONED_DIRECTORY
2
Answers
Unfortunately,
next export
does not support the experimentalappDir
setting.For more information, checkout: https://beta.nextjs.org/docs/app-directory-roadmap
This feature now is supported in Next 13.3
For more information, checkout: https://beta.nextjs.org/docs/app-directory-roadmap#configuration