Added test files

This commit is contained in:
2021-10-24 15:53:57 +02:00
parent b0f82d471e
commit 7f82b25cde
4 changed files with 138 additions and 0 deletions

14
test/deploy.sh Executable file
View File

@@ -0,0 +1,14 @@
#!/bin/sh
set -e
echo "Deploying for $GIT_REPO_URL"
CONTENT_DIR=$(mktemp -d -t ci-XXXXXXXXXX)
echo "Working directory: ${CONTENT_DIR}"
mkdir -p ${CONTENT_DIR}
GIT_SSH_COMMAND="ssh -oStrictHostKeyChecking=no -i ${GIT_SSH_ID_FILE}" git clone ${GIT_REPO_URL} ${CONTENT_DIR}
# mkdir -p ${TARGET_DIR}
cd ${CONTENT_DIR} && hugo ${HUGO_PARAMS}
rm -rf ${CONTENT_DIR}