This commit is contained in:
Leandro Facchinetti 2020-03-21 01:43:17 -04:00
parent df1b2b0d90
commit 218e5c6117
1 changed files with 5 additions and 13 deletions

View File

@ -2,7 +2,8 @@
"scripts": {
"start": "concurrently \"tsc --watch\" \"nodemon lib\"",
"test": "tsc && jest && prettier --check 'src/**'",
"deploy": "pm2 deploy package.json production"
"deploy": "pm2 deploy package.json production",
"deploy:start": "pm2 startOrRestart package.json"
},
"dependencies": {
"crypto-random-string": "^3.2.0",
@ -53,25 +54,16 @@
"deploy": {
"production": {
"user": "root",
"host": "204.48.21.111",
"host": "kill-the-newsletter.com",
"ref": "origin/master",
"repo": "git@github.com:leafac/www.kill-the-newsletter.com.git",
"path": "/root/www.kill-the-newsletter.com",
"pre-setup": "(curl -sL https://deb.nodesource.com/setup_13.x | bash -) && apt install -y nodejs build-essential && (curl https://getcaddy.com | bash -s personal) && (ssh -o StrictHostKeyChecking=no git@github.com || true)",
"pre-deploy-local": "rsync -av --delete lib/ root@kill-the-newsletter.com:www.kill-the-newsletter.com/current/lib/",
"post-deploy": "env NODE_ENV=production npm ci && npm deploy:start",
"ssh_options": [
"ForwardAgent=yes",
"StrictHostKeyChecking=no"
],
"TODO": [
"/root/www.kill-the-newsletter.com/current/node_modules/.bin/pm2 startOrRestart all",
"env NODE_ENV=production npm ci",
"rsync",
"pm2 startup OR pm2 save",
"pm2 start env.js",
"https://pm2.keymetrics.io/docs/usage/deployment/",
"https://pm2.keymetrics.io/docs/usage/startup/",
"host: kill-the-newsletter.com",
"test: basic application workflow, previously created newsletter, /feeds/ directory listing, port 8000 isnt responding"
]
}
}