Skip to content
Snippets Groups Projects
Commit b4e7ab94 authored by Hahn Axel (hahn)'s avatar Hahn Axel (hahn)
Browse files

replace docker-compose with "docker compose"

parent c7fbbe78
No related branches found
No related tags found
1 merge request!6Replace docker compose
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
# 2022-12-20 v1.4 <axel.hahn@unibe.ch> replace fgrep with grep -F # 2022-12-20 v1.4 <axel.hahn@unibe.ch> replace fgrep with grep -F
# 2023-03-06 v1.5 <www.axel-hahn.de> up with and without --build # 2023-03-06 v1.5 <www.axel-hahn.de> up with and without --build
# 2023-08-17 v1.6 <www.axel-hahn.de> menu selection with single key (without return) # 2023-08-17 v1.6 <www.axel-hahn.de> menu selection with single key (without return)
# 2023-11-10 v1.7 <axel.hahn@unibe.ch> replace docker-compose with "docker compose"
# ====================================================================== # ======================================================================
cd $( dirname $0 ) cd $( dirname $0 )
...@@ -19,7 +20,7 @@ cd $( dirname $0 ) ...@@ -19,7 +20,7 @@ cd $( dirname $0 )
# git@git-repo.iml.unibe.ch:iml-open-source/docker-php-starterkit.git # git@git-repo.iml.unibe.ch:iml-open-source/docker-php-starterkit.git
selfgitrepo="docker-php-starterkit.git" selfgitrepo="docker-php-starterkit.git"
_version="1.6" _version="1.7"
# ---------------------------------------------------------------------- # ----------------------------------------------------------------------
# FUNCTIONS # FUNCTIONS
...@@ -259,10 +260,10 @@ while true; do ...@@ -259,10 +260,10 @@ while true; do
echo " $( _key t ) - generate files from templates" echo " $( _key t ) - generate files from templates"
echo " $( _key T ) - remove generated files" echo " $( _key T ) - remove generated files"
echo echo
echo " $( _key u ) - startup containers docker-compose ... up -d" echo " $( _key u ) - startup containers docker compose ... up -d"
echo " $( _key U ) - startup containers docker-compose ... up -d --build" echo " $( _key U ) - startup containers docker compose ... up -d --build"
echo " $( _key s ) - shutdown containers docker-compose stop" echo " $( _key s ) - shutdown containers docker compose stop"
echo " $( _key r ) - remove containers docker-compose rm -f" echo " $( _key r ) - remove containers docker compose rm -f"
echo echo
echo " $( _key m ) - more infos" echo " $( _key m ) - more infos"
echo " $( _key c ) - console (bash)" echo " $( _key c ) - console (bash)"
...@@ -300,7 +301,7 @@ while true; do ...@@ -300,7 +301,7 @@ while true; do
_wait _wait
;; ;;
u|U) u|U)
dockerUp="docker-compose -p "$APP_NAME" --verbose up -d --remove-orphans" dockerUp="docker compose -p "$APP_NAME" --verbose up -d --remove-orphans"
if [ "$action" = "U" ]; then if [ "$action" = "U" ]; then
dockerUp+=" --build" dockerUp+=" --build"
fi fi
...@@ -308,18 +309,18 @@ while true; do ...@@ -308,18 +309,18 @@ while true; do
echo "In a web browser:" echo "In a web browser:"
echo " $frontendurl" echo " $frontendurl"
else else
echo "ERROR: docker-compose up failed :-/" echo "ERROR: docker compose up failed :-/"
docker-compose -p "$APP_NAME" logs | tail docker compose -p "$APP_NAME" logs | tail
fi fi
echo echo
_wait _wait
;; ;;
s) s)
docker-compose -p "$APP_NAME" stop docker compose -p "$APP_NAME" stop
;; ;;
r) r)
docker-compose -p "$APP_NAME" rm -f docker compose -p "$APP_NAME" rm -f
;; ;;
c) c)
docker ps docker ps
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment