From 30f1bcebcc5da7b513a0aecaf60bc7e69ad6ba38 Mon Sep 17 00:00:00 2001 From: Rodolfo Berrios <20590102+rodber@users.noreply.github.com> Date: Tue, 2 Dec 2025 14:13:30 -0300 Subject: [PATCH] add ns compose --- Makefile | 5 ++++- docs/DOCKER-COMPOSE.md | 2 ++ docs/NAMESPACE.md | 5 +++-- scripts/system/namespace.sh | 1 + 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 148a4f2..6bac6e1 100644 --- a/Makefile +++ b/Makefile @@ -16,8 +16,10 @@ ifneq ("$(wildcard ${ENV_FILE})","") export $(shell sed 's/=.*//' ${ENV_FILE}) endif SOURCE ?= ~/git/chevereto/v4 +# For legacy reasons, default uses mariadb. +# Newer installations recommend TARGET=default-mysql instead. TARGET ?= default# default|dev -VERSION ?= 4.3 +VERSION ?= 4.4 PHP ?= 8.2 EDITION ?= $(shell [ "${CHEVERETO_LICENSE_KEY}" = "" ] && echo free || echo pro) DOCKER_USER ?= www-data @@ -216,6 +218,7 @@ namespace: NAMESPACE_EXISTS=${NAMESPACE_EXISTS} \ NAMESPACE_FILE=${NAMESPACE_FILE} \ HOSTNAME=${HOSTNAME} \ + COMPOSE=${COMPOSE} \ ENCRYPTION_KEY=${ENCRYPTION_KEY} \ ./scripts/system/namespace.sh diff --git a/docs/DOCKER-COMPOSE.md b/docs/DOCKER-COMPOSE.md index 8972cfe..315b529 100644 --- a/docs/DOCKER-COMPOSE.md +++ b/docs/DOCKER-COMPOSE.md @@ -2,6 +2,8 @@ This project includes shortcuts for running `docker compose` commands. It uses `default.yml` but it can also use your own compose file. +**Note:** For legacy reasons this project uses `default.yml` (MariaDB) as the default compose file. We recommend using `default-mysql.yml` for MySQL setups. + * Requires [Compose V2](https://docs.docker.com/compose/cli-command/) * Place a `docker-compose.yml` file to use your own instead of [default.yml](../default.yml) * Pass `COMPOSE=my-compose` to use `my-compose.yml` diff --git a/docs/NAMESPACE.md b/docs/NAMESPACE.md index 3c059f9..4a46641 100644 --- a/docs/NAMESPACE.md +++ b/docs/NAMESPACE.md @@ -12,11 +12,12 @@ Required options: * NAMESPACE=chevereto * HOSTNAME=localhost +* COMPOSE=default-mysql -For example, to create the `nasa` namespace for `photos.nasa.gov`: +For example, to create the `nasa` namespace for `photos.nasa.gov` and using the `default-mysql` compose file run: ```sh -make namespace NAMESPACE=nasa HOSTNAME=photos.nasa.gov +make namespace NAMESPACE=nasa HOSTNAME=photos.nasa.gov COMPOSE=default-mysql ``` This will create `./namespace/nasa` with the minimum namespaced scoped variables required: diff --git a/scripts/system/namespace.sh b/scripts/system/namespace.sh index e08f2a1..a740855 100755 --- a/scripts/system/namespace.sh +++ b/scripts/system/namespace.sh @@ -11,6 +11,7 @@ if [ "${ENCRYPTION_KEY}" == "" ]; then fi mkdir -p $(dirname ${NAMESPACE_FILE}) cat >${NAMESPACE_FILE} <