Commit 48290654 authored by Michael Ochmann's avatar Michael Ochmann
Browse files

added continous deployment

parent dada41eb
Pipeline #2590 failed with stage
in 19 seconds
image: node:alpine
stages:
- deploy
deploy:
stage: deploy
before_script:
- 'which ssh-agent || ( apk add --update openssh )'
- apk add --update bash
- apk add --update git
- eval $(ssh-agent -s)
- echo "$SSH_PRIVATE_KEY" | ssh-add -
- mkdir -p ~/.ssh
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
script:
- npm i -g pm2
- pm2 deploy ecosystem.config.js production
only:
- master
- development
......@@ -4,6 +4,7 @@ div.login {
left: 0;
width: 100%;
height: 100%;
display: none;
form {
position: absolute;
......
......@@ -21,8 +21,14 @@ body {
margin: 0;
padding: 0;
font-family: sans-serif;
}
header, main, footer {
&.login {
header, main, footer {
filter: blur(10px);
}
div.login {
display: block;
}
}
}
module.exports = {
apps : [{
name: 'beacon',
script: 'main.js',
// Options reference: https://pm2.io/doc/en/runtime/reference/ecosystem-file/
instances: 1,
autorestart: true,
watch: false,
max_memory_restart: '1G',
env: {
NODE_ENV: 'development'
},
env_production: {
NODE_ENV: 'production'
}
}],
deploy : {
production : {
user : 'fsi',
host : 'uberspace.fsi.rocks',
ref : 'origin/development',
repo : 'git@gitlab.fsi.hochschule-trier.de:ochmannm/beacon.git',
path : '/home/fsi/bin/beacon',
'post-deploy' : 'npm install && pm2 reload ecosystem.config.js --env production'
}
}
};
......@@ -4253,7 +4253,8 @@ div.login {
top: 0;
left: 0;
width: 100%;
height: 100%; }
height: 100%;
display: none; }
div.login form {
position: absolute;
top: 50%;
......@@ -4313,6 +4314,7 @@ body {
margin: 0;
padding: 0;
font-family: sans-serif; }
header, main, footer {
body.login header, body.login main, body.login footer {
filter: blur(10px); }
body.login div.login {
display: block; }
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment