mainly more echos
This commit is contained in:
8
assets/example.org.conf
Normal file
8
assets/example.org.conf
Normal file
@@ -0,0 +1,8 @@
|
||||
<VirtualHost *:80>
|
||||
ServerAdmin webmaster@example.org
|
||||
ServerName example.org
|
||||
ServerAlias www.example.org
|
||||
DocumentRoot /srv/www/example.org/public_html/
|
||||
ErrorLog /srv/www/example.org/logs/error.log
|
||||
CustomLog /srv/www/example.org/logs/access.log combined
|
||||
</VirtualHost>
|
18
assets/git-post-reveive
Normal file
18
assets/git-post-reveive
Normal file
@@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
#hook/post-receive
|
||||
#CONFIG
|
||||
|
||||
PRODDIR="www"
|
||||
|
||||
read oldrev newrev refname
|
||||
if [ $refname = "refs/heads/prod" ]; then
|
||||
echo "===== DEPLOYING APP ====="
|
||||
unset GIT_DIR
|
||||
cd ~
|
||||
cd $PRODDIR
|
||||
git pull --ff-only origin prod
|
||||
echo $?
|
||||
echo "====== OK ====="
|
||||
else
|
||||
echo "Warning Commit not deployed, please use prod branch"
|
||||
fi
|
17
assets/git-pre-receive
Normal file
17
assets/git-pre-receive
Normal file
@@ -0,0 +1,17 @@
|
||||
#!/bin/bash
|
||||
#hook/pre-receive
|
||||
#CONFIG
|
||||
PRODDIR="www"
|
||||
|
||||
read oldrev newrev refname
|
||||
if [ $refname = "refs/heads/prod" ]; then
|
||||
echo "===== UPDATE REPOSITORY ====="
|
||||
unset GIT_DIR
|
||||
cd ~
|
||||
cd $PRODDIR
|
||||
git add .
|
||||
git commit -m "Auto Commit"
|
||||
echo "====== OK ====="
|
||||
else
|
||||
echo "Warning Commit not deployed, please use prod branch"
|
||||
fi
|
Reference in New Issue
Block a user