This repository has been archived on 2026-04-16. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files

31 lines
593 B
Bash
Raw Permalink Normal View History

2022-11-30 16:30:37 +01:00
#!/bin/bash
2023-04-30 15:40:27 +02:00
source "../build-functions.sh"
source "../build-config.sh"
2022-11-30 16:30:37 +01:00
2022-11-30 16:31:54 +01:00
DOCKER_IMAGE_NAME="daniel156161/mariadb-teleport"
2022-11-30 16:30:37 +01:00
2023-04-30 15:40:27 +02:00
function run_docker_container {
2022-11-30 16:30:37 +01:00
echo "Running..."
2023-01-08 13:05:49 +01:00
docker run -it -d \
2022-11-30 16:30:37 +01:00
-p 3306:3306 \
2023-01-08 13:05:49 +01:00
-p 80:80 \
-v "$PWD/certs:/certs/" \
2022-11-30 16:30:37 +01:00
-e TZ="Europe/Vienna" \
-e MARIADB_ALLOW_EMPTY_ROOT_PASSWORD="true" \
2022-12-04 03:42:24 +01:00
-e RUN_WEBSERVER="yes" \
2023-04-30 15:40:27 +02:00
"$DOCKER_IMAGE_NAME:$GIT_BRANCH"
2022-11-30 16:30:37 +01:00
}
case "$1" in
run)
run_docker_container
;;
build)
2023-04-30 15:40:27 +02:00
build_docker_image "$DOCKER_IMAGE_NAME:$GIT_BRANCH"
2022-11-30 16:30:37 +01:00
;;
*)
2023-04-30 15:40:27 +02:00
echo "Usage: $0 {run|build}"
2022-11-30 16:30:37 +01:00
exit 1
;;
esac