From 2fabe99d72c0c2a3b6d3ba2481a48e6d74cf7e8d Mon Sep 17 00:00:00 2001 From: Slawomir Koszewski Date: Mon, 4 May 2026 19:59:55 +0200 Subject: [PATCH] Make run-container.sh executable and ensure container command availability --- scripts/run-container.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) mode change 100644 => 100755 scripts/run-container.sh diff --git a/scripts/run-container.sh b/scripts/run-container.sh old mode 100644 new mode 100755 index 7e96b6b..8b9a7da --- a/scripts/run-container.sh +++ b/scripts/run-container.sh @@ -2,3 +2,19 @@ set -e +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" + +if command -v container >/dev/null 2>&1; then + container run -d --name ldap \ + --env-file ~/app-data/openldap/openldap.env \ + -v openldap_data:/var/lib/ldap \ + -v openldap_slapd:/etc/ldap/slapd.d \ + -v ~/app-data/openldap/certs:/etc/ldap/certs:ro \ + -v ~/app-data/openldap/accounts:/bootstrap/accounts:ro \ + -v ~/app-data/openldap/backups:/var/backups:rw \ + -p 389:389 -p 636:636 \ + openldap:latest +else + echo "Error: 'container' command not found. Please install the 'container' CLI tool." >&2 + exit 1 +fi \ No newline at end of file