This commit is contained in:
9
.github/workflows/deploy.yml
vendored
9
.github/workflows/deploy.yml
vendored
@@ -33,12 +33,9 @@ jobs:
|
|||||||
- name: Deploy website
|
- name: Deploy website
|
||||||
run: |
|
run: |
|
||||||
MACHINE_IP="$(tailscale ip -4 $MACHINE_NAME)"
|
MACHINE_IP="$(tailscale ip -4 $MACHINE_NAME)"
|
||||||
ssh -i ~/.ssh/key "kenneth@$MACHINE_IP" /bin/bash << EOF
|
ssh -i ~/.ssh/key "$MACHINE_USER_NAME:@$MACHINE_IP" /bin/bash << EOF
|
||||||
cd /opt/website
|
cd /opt/website
|
||||||
git pull
|
git pull
|
||||||
docker build -t website .
|
cd ../
|
||||||
docker stop website-container
|
docker compose up --build --detach website
|
||||||
docker rm website-container
|
|
||||||
docker run --name=website-container --restart=always --publish 5432:80 --detach website
|
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user