英文:
next js app directory github action CI/CD path
问题
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
英文:
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
答案1
得分: 2
这个功能现在在 Next 13.3 中得到支持。
更多信息,请查看:https://beta.nextjs.org/docs/app-directory-roadmap#configuration。
英文:
This feature now is supported in Next 13.3
For more information, checkout: <https://beta.nextjs.org/docs/app-directory-roadmap#configuration>
答案2
得分: 0
抱歉,next export
不支持实验性的 appDir
设置。
更多信息,请查看:https://beta.nextjs.org/docs/app-directory-roadmap
英文:
Unfortunately, next export
does not support the experimental appDir
setting.
For more information, checkout: https://beta.nextjs.org/docs/app-directory-roadmap
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论