refactor(bookstack): extract into own pod

This commit is contained in:
Marc 2024-03-31 14:52:39 -04:00
parent 78b5afacaa
commit ed73fa0659
Signed by: marc
GPG key ID: 048E042F22B5DC79
2 changed files with 17 additions and 15 deletions

27
services/bookstack/start.sh Normal file → Executable file
View file

@ -2,19 +2,24 @@
source constants.sh source constants.sh
podman pod create \
-p 3010:80 \
--replace \
"bookstack"
podman run \ podman run \
--detach \ -d \
--pod services \ --pod "bookstack" \
--name $DB_CONTAINER_NAME \ --name "$DB_CONTAINER_NAME" \
--env-file $ENV_FILE_DIR/bookstack-db.env \ --env-file "$ENV_FILE_DIR"/bookstack-db.env \
--mount type=bind,source=$APP_DATA_DIR/bookstack-db,target=/var/lib/mysql \ --mount type=bind,source="$APP_DATA_DIR"/bookstack-db,target=/var/lib/mysql \
mariadb:10.6 \ mariadb:10.6 \
--port 3307 --port 3307
podman run \ podman run \
--detach \ -d \
--pod services \ --pod "bookstack" \
--name $APP_CONTAINER_NAME \ --name "$APP_CONTAINER_NAME" \
--env-file $ENV_FILE_DIR/bookstack-app.env \ --env-file "$ENV_FILE_DIR"/bookstack-app.env \
--mount type=bind,source=$APP_DATA_DIR/bookstack-app,target=/config \ --mount type=bind,source="$APP_DATA_DIR"/bookstack-app,target=/config \
$APP_IMAGE_NAME:$IMAGE_VERSION "$APP_IMAGE_NAME:$IMAGE_VERSION"

5
services/bookstack/stop.sh Normal file → Executable file
View file

@ -1,6 +1,3 @@
#!/bin/bash #!/bin/bash
source constants.sh podman pod stop "bookstack"
podman rm -f $APP_CONTAINER_NAME
podman rm -f $DB_CONTAINER_NAME