|
@ -1,7 +1,7 @@ |
|
|
#!/bin/bash |
|
|
#!/bin/bash |
|
|
|
|
|
|
|
|
function check_service_running() { |
|
|
function check_service_running() { |
|
|
lxc exec "$container" -- bash -c "docker ps --format '{{.Names}},{{.Ports}}' | grep $1 | grep $2" |
|
|
|
|
|
|
|
|
lxc exec "$container" -- bash -c "docker ps --format '{{.Names}},{{.Ports}}' | grep $1 | grep -q $2" |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
function _read() { |
|
|
function _read() { |
|
@ -10,7 +10,6 @@ function _read() { |
|
|
check_container "$container" |
|
|
check_container "$container" |
|
|
check_service_running "$longname" "$port" |
|
|
check_service_running "$longname" "$port" |
|
|
enable_trace |
|
|
enable_trace |
|
|
return 0 |
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
function _create() { |
|
|
function _create() { |
|
|