migrating to @warren-bank/serve and better naming

This commit is contained in:
Firq 2023-07-27 23:45:56 +02:00
parent 26b732f29e
commit 92debcd2f7
Signed by: Firq
GPG key ID: 3ACC61C8CEC83C20
2 changed files with 18 additions and 12 deletions

View file

@ -59,11 +59,11 @@ deploy-site:
- echo "Getting artifacts" - echo "Getting artifacts"
- ls public - ls public
- echo "Stopping screen session, cleaning" - echo "Stopping screen session, cleaning"
- ssh $DEPLOY_USER@$DEPLOY_HOST "screen -X -S website-fgota-npx kill; rm -r -f fgo-ta_com/fgota-public/*;" - ssh $DEPLOY_USER@$DEPLOY_HOST "screen -X -S fgo-ta_com-public kill; rm -r -f fgo-ta_com/public/*;"
- echo "Copying to proxmox machine" - echo "Copying to proxmox machine"
- rsync -az --stats public/* $DEPLOY_USER@$DEPLOY_HOST:~/fgo-ta_com/fgota-public - rsync -az --stats public/* $DEPLOY_USER@$DEPLOY_HOST:~/fgo-ta_com/public
- echo "Restarting screen session" - echo "Restarting screen session"
- ssh $DEPLOY_USER@$DEPLOY_HOST "cd fgo-ta_com; find fgota-public -maxdepth 1 -printf '%p\n'; screen -S website-fgota-npx -dm npx serve fgota-public/ -p 9200 -c serve.json" - ssh $DEPLOY_USER@$DEPLOY_HOST "cd fgo-ta_com; find public -maxdepth 1 -printf '%p\n'; screen -S fgo-ta_com-public -dm ~/serve public/ -p 9200"
- echo "Website is up on https://fgo-ta.com" - echo "Website is up on https://fgo-ta.com"
@ -80,5 +80,5 @@ redeploy-site:
- echo "Stopping screen session" - echo "Stopping screen session"
- ssh $DEPLOY_USER@$DEPLOY_HOST "screen -X -S website-fgota-npx kill" || true - ssh $DEPLOY_USER@$DEPLOY_HOST "screen -X -S website-fgota-npx kill" || true
- echo "Restarting screen session" - echo "Restarting screen session"
- ssh $DEPLOY_USER@$DEPLOY_HOST "cd fgo-ta_com; screen -S website-fgota-npx -dm npx serve fgota-public/ -p 9200 -c serve.json" - ssh $DEPLOY_USER@$DEPLOY_HOST "cd fgo-ta_com; screen -S fgo-ta_com-public -dm ~/serve public/ -p 9200"
- echo "Website is up on https://fgo-ta.com/" - echo "Website is up on https://fgo-ta.com/"

View file

@ -1,14 +1,20 @@
{ {
"directoryListing": ["/!assets/**"], "cleanUrls": true,
"directoryListing": false,
"etag": true,
"headers": [ "headers": [
{ {
"source": "**/*.@(jpg|jpeg|gif|png|webp)", "source" : "**/*.@(jpg|jpeg|gif|png|webp|svg)",
"headers": [ "headers" : [{
{ "key" : "Cache-Control",
"key": "Cache-Control", "value" : "no-cache"
"value": "no-cache" }]
} }, {
] "source" : "404.html",
"headers" : [{
"key" : "Cache-Control",
"value" : "no-cache"
}]
} }
] ]
} }