[Skip-Ci] Update Docker image, cron job, tests
It seems, timeout sends signals that do not stop the server process. Set the signal to SIGKILL - which also kills the function.sh process. Thus moved the last function to entrypoint.shmerge-requests/1/merge
parent
bcad22b067
commit
46f0c72c3e
@ -1,17 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
function get-and-unzip-website-data() {
|
||||
curl -H "Authorization: token $AUTHTOKEN" -O $GITREPOURL # GITREPURL = https://your.gitea.host/api/v1/repos/<owner>/<repo>/archive/main.zip
|
||||
mkdir $BUILDDIR
|
||||
unzip main.zip -D $BUILDDIR
|
||||
filename="website.zip"
|
||||
curl -H "Authorization: token $AUTHTOKEN" -o $SOURCEDIR/$filename $GITREPOURL # GITREPURL = https://your.gitea.host/api/v1/repos/<owner>/<repo>/archive/main.zip
|
||||
unzip $SOURCEDIR/$filename -d $BUILDDIR
|
||||
}
|
||||
|
||||
function build-and-extract-website() {
|
||||
(cd $BUILDDIR; lein ring war; websiteartifactname=$(ls | grep -o *.war); unzip target/$websiteartifactname "WEB-INF/classes/public/*")
|
||||
}
|
||||
|
||||
# set variables from environment
|
||||
# read write zugriff sicherstellen
|
||||
function move-website-files-to-target() {
|
||||
rsync -ru --exclude-from "/etc/exclude.pattern" --delete WEB-INF/classes/public/* $TARGETDIR
|
||||
(cd $BUILDDIR; dir=$(ls); cd $dir; timeout -s SIGKILL 35s lein ring server-headless;)
|
||||
# websiteartifactname=$(ls target/ | grep -Eo "*.+\.war"); unzip target/$websiteartifactname
|
||||
}
|
||||
|
Loading…
Reference in New Issue