mirror of
https://github.com/Dokploy/examples
synced 2025-06-26 18:15:52 +00:00
.. | ||
public | ||
server | ||
.gitignore | ||
app.vue | ||
nuxt.config.ts | ||
package.json | ||
pnpm-lock.yaml | ||
README.md | ||
tsconfig.json |
Nuxt Example
This repository contains an example of a Nuxt application that is deployed on Dokploy. There are two ways to deploy this application:
- With server side rendering
- As a static site
All examples assume you use Nixpacks
as the build type.
Server side rendering
-
Use Git Provider in Your Application:
- Repository:
https://github.com/Dokploy/examples.git
- Branch:
main
- Build path:
/nuxt
- Repository:
-
Add Environment Variables:
-
Navigate to the "Environments" tab and add the following variable:
NIXPACKS_START_CMD="node .output/server/index.mjs"
-
Click on Deploy:
- Deploy your application by clicking the deploy button.
-
Generate a Domain:
- Click on generate domain button.
- A new domain will be generated for you.
- You can use this domain to access your application.
Static site
-
Use Git Provider in Your Application:
- Repository:
https://github.com/Dokploy/examples.git
- Branch:
main
- Build path:
/nuxt
- Repository:
-
Add Environment Variables:
-
Navigate to the "Environments" tab and add the following variable:
NIXPACKS_BUILD_CMD="pnpm generate"
- Set the publish directory:
- Ensure you set it to
dist/
. Note that there is no dot beforedist
!
-
Click on Deploy:
- Deploy your application by clicking the deploy button.
-
Generate a Domain:
- Click on generate domain button.
- A new domain will be generated for you.
- You can use this domain to access your application.
- Set the port to 80
If you need further assistance, join our Discord server.