„.drone.yml“ ändern
continuous-integration/drone/push Build is failing Details

main
michael 1 year ago
parent ff379ceb08
commit 8d2cda8f19

@ -20,16 +20,15 @@ steps:
- name: shared
path: /tmp/shared
- name: serve
- name: export
image: python:3.7-alpine
environment:
SSH_KEY:
from_secret: SSH_KEY
username:
from_secret: username
password:
from_secret: password
commands:
- apk add unzip wget make git curl openssh
- mkdir /root/.ssh && echo "$SSH_KEY" > /root/.ssh/id_rsa && chmod 0600 /root/.ssh/id_rsa
- git config --global user.name "Drone CI"
- git config --global user.email "drone@omglinux.de"
- mkdir /tmp/content
- curl https://cloud.fdgl.rocks/index.php/s/wGLnSaTiL2rn5ae/download -o /tmp/content.zip
- unzip /tmp/content.zip -d /tmp
@ -40,13 +39,26 @@ steps:
- source /tmp/shared/.venv/bin/activate
- nohup python3 app.py 2>&1 > /dev/null &
- sleep 3
- ssh-keyscan -H git.omglinux.de -p 2222 >> ~/.ssh/known_hosts
- git clone ssh://git@git.omglinux.de:2222/michael/fdgl-production.git /tmp/shared/target
- git clone https://git.omglinux.de/michael/fdgl-production.git /tmp/shared/target
- cd /tmp/shared/target
- wget -mpEk http://127.0.0.1:5000 2>&1 > /dev/null || true
- git add -A
- git commit -m "automatic commit $(date)"
- git push origin main
volumes:
- name: shared
path: /tmp/shared
- name: push
image: appleboy/drone-git-push
settings:
branch: main
remote: ssh://git@git.omglinux.de:2222/michael/fdgl-production.git
force: false
commit: true
commit_message: "Drone build ${DRONE_COMMIT_SHA:0:7}"
author_name: "Drone CI"
author_email: "drone@omglinux.de"
path: /tmp/shared/target
ssh_key:
from_secret: ssh_key
volumes:
- name: shared
path: /tmp/shared

Loading…
Cancel
Save