generated from Flycro/laravel-nuxt
fix: Hash in Build #4
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -27,5 +27,6 @@ steps:
|
|||||||
- pnpm run build
|
- pnpm run build
|
||||||
- find /var/www/html/bookstack.octolabs.net -type f -exec chmod 664 {} \\;
|
- find /var/www/html/bookstack.octolabs.net -type f -exec chmod 664 {} \\;
|
||||||
- find /var/www/html/bookstack.octolabs.net -type d -exec chmod 775 {} \\;
|
- find /var/www/html/bookstack.octolabs.net -type d -exec chmod 775 {} \\;
|
||||||
- env HOME=/home/flycro pm2 stop ecosystem.config.cjs
|
- export GIT_HASH=$(git rev-parse --short HEAD)
|
||||||
- env HOME=/home/flycro pm2 start ecosystem.config.cjs
|
- env HOME=/home/flycro GIT_HASH=$GIT_HASH pm2 stop ecosystem.config.cjs
|
||||||
|
- env HOME=/home/flycro GIT_HASH=$GIT_HASH pm2 start ecosystem.config.cjs
|
||||||
|
|||||||
@@ -5,7 +5,10 @@ module.exports = {
|
|||||||
port: '3377',
|
port: '3377',
|
||||||
exec_mode: 'cluster',
|
exec_mode: 'cluster',
|
||||||
instances: 'max',
|
instances: 'max',
|
||||||
script: './.output/server/index.mjs'
|
script: './.output/server/index.mjs',
|
||||||
|
env_production: {
|
||||||
|
"GIT_HASH": process.env.GIT_HASH,
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,9 +5,9 @@
|
|||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"serve": "cross-env PORT=3000 HOST=127.0.0.1 node .output/server/index.mjs",
|
"serve": "cross-env PORT=3000 HOST=127.0.0.1 node .output/server/index.mjs",
|
||||||
"build": "GIT_HASH=`git rev-parse --short HEAD` nuxi build",
|
"build": "GIT_HASH=$(git rev-parse --short HEAD) nuxi build",
|
||||||
"cleanup": "nuxi cleanup",
|
"cleanup": "nuxi cleanup",
|
||||||
"dev": "GIT_HASH=`git rev-parse --short HEAD` nuxt dev --port=3000 --host=127.0.0.1",
|
"dev": "GIT_HASH=$(git rev-parse --short HEAD) nuxt dev --port=3000 --host=127.0.0.1",
|
||||||
"generate": "nuxt generate",
|
"generate": "nuxt generate",
|
||||||
"preview": "nuxt preview",
|
"preview": "nuxt preview",
|
||||||
"postinstall": "nuxt prepare",
|
"postinstall": "nuxt prepare",
|
||||||
|
|||||||
Reference in New Issue
Block a user