Update server subcommands

This commit is contained in:
3wc
2020-10-26 11:58:15 +02:00
parent d37d8a0c66
commit 6cf7cf843a
2 changed files with 15 additions and 7 deletions

10
abra
View File

@ -530,7 +530,11 @@ sub_cp() {
###### Subcommand `context`
sub_server_init() {
load_context
export DOCKER_CONTEXT="$1"
if [ -n "$DOCKER_CONTEXT" ]; then
load_context
fi
docker swarm init || true
docker network create --driver=overlay proxy --scope swarm || true
@ -562,6 +566,10 @@ sub_server_use() {
docker context use "$1"
}
sub_server_ls() {
docker context ls
}
sub_server() {
SUBCOMMAND2=$1
shift