File tree 3 files changed +23
-1
lines changed
3 files changed +23
-1
lines changed Original file line number Diff line number Diff line change
1
+ language : node_js
2
+ node_js :
3
+ - " 11"
4
+
5
+ deploy :
6
+ provider : script
7
+ script : bash scripts/deploy.sh
8
+ on :
9
+ tags : true
Original file line number Diff line number Diff line change 4
4
"description" : " Discord bot for r/webdev" ,
5
5
"main" : " app.js" ,
6
6
"scripts" : {
7
- "test" : " echo \" Error: no test specified\" && exit 1 " ,
7
+ "test" : " echo \" Error: no test specified\" && exit" ,
8
8
"start" : " node app.js"
9
9
},
10
10
"author" : " rwebdev" ,
Original file line number Diff line number Diff line change
1
+ #! /bin/sh
2
+ # Generic deployment script for webster.
3
+ export RSYNC_DESTINATION=" webster@${PRODUCTION_SERVER} :/home/webster/discord-bot"
4
+
5
+ which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )
6
+
7
+ eval $( ssh-agent -s)
8
+ ssh-add <( echo " $DEPLOY_KEY " )
9
+ mkdir -p ~ /.ssh
10
+ echo " $HOST_FINGERPRINT " >> ~ /.ssh/known_hosts
11
+
12
+ rsync -av --no-perms --no-owner --no-group --exclude ' .git' ./ " ${RSYNC_DESTINATION} /"
13
+ ssh " webster@${PRODUCTION_SERVER} " ' cd discord-bot/; npm install'
You can’t perform that action at this time.
0 commit comments