From 9c85329e682d527e2719cf8716f49e883877bde0 Mon Sep 17 00:00:00 2001 From: Marcell Nagy Date: Wed, 23 Oct 2024 11:28:56 +0100 Subject: [PATCH 1/2] alias ec to dc --- template/compose/environment.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/template/compose/environment.sh b/template/compose/environment.sh index 5b9e9a4..711cd9c 100644 --- a/template/compose/environment.sh +++ b/template/compose/environment.sh @@ -52,4 +52,4 @@ export COMPOSE_PROFILES=test # for test profile our ca-gateway publishes PVS on the loopback interface export EPICS_CA_ADDR_LIST=127.0.0.1 # make a short alias for docker-compose for convenience -alias ec='docker compose' +alias dc='docker compose' From a6198d24d10c49868b1445cb0efbb09ac48eee81 Mon Sep 17 00:00:00 2001 From: Marcell Nagy Date: Wed, 23 Oct 2024 12:45:33 +0100 Subject: [PATCH 2/2] Remove alias local dependancy in script --- template/compose/environment.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/template/compose/environment.sh b/template/compose/environment.sh index 711cd9c..5dec6b6 100644 --- a/template/compose/environment.sh +++ b/template/compose/environment.sh @@ -30,14 +30,16 @@ function check_docker { if check_docker; then USER_ID=$(id -u); USER_GID=$(id -g) + docker="docker" else USER_ID=0; USER_GID=0 alias docker=podman + docker="podman" fi # make sure we have a network to share beteen the devcontainer and gateway container -if ! docker network inspect channel_access_devcontainer &>/dev/null ; then - docker network create --subnet="170.21.0.0/16" channel_access_devcontainer +if ! $docker network inspect channel_access_devcontainer &>/dev/null ; then + $docker network create --subnet="170.21.0.0/16" channel_access_devcontainer fi # ensure local container users can access X11 server