maybe this will work
This commit is contained in:
parent
3475c31d71
commit
8d7251f2d2
1 changed files with 21 additions and 0 deletions
21
.gitlab-ci.yml
Normal file
21
.gitlab-ci.yml
Normal file
|
@ -0,0 +1,21 @@
|
|||
stages:
|
||||
- deploy
|
||||
|
||||
deploy-job:
|
||||
stage: deploy
|
||||
image: ubuntu:latest
|
||||
before_script:
|
||||
- apt-get update
|
||||
- apt-get install -y rsync openssh-client hugo git sshpass
|
||||
|
||||
script:
|
||||
- git clone https://git.fzorb.xyz/fzorb/website
|
||||
- cd website
|
||||
- git submodule foreach --recursive git reset --hard && git submodule init && git submodule update --recursive
|
||||
- hugo
|
||||
- ssh-keyscan -p 69 fzorb.xyz >> ~/.ssh/known_hosts
|
||||
- sshpass -p "$PASSWD" rsync -avzh website/public/ -e 'ssh -p 69' git@fzorb.xyz:/var/www/fzorb.xyz
|
||||
- sshpass -p "$PASSWD" ssh -p 69 git@fzorb.xyz "chmod 777 -R /var/www/fzorb.xyz"
|
||||
|
||||
only:
|
||||
- main
|
Loading…
Add table
Add a link
Reference in a new issue