mirror of
https://github.com/home-assistant/operating-system.git
synced 2025-07-28 07:26:28 +00:00
Change login cli
This commit is contained in:
parent
10d6025f27
commit
3efe1618a0
@ -7,12 +7,10 @@ CLI="$(jq --raw-output '.cli' ${CONFIG_FILE})"
|
||||
DOCKER_ARGS="$(jq --raw-output '.cli_args // empty' ${CONFIG_FILE})"
|
||||
CLI_DATA=/mnt/data/cli
|
||||
|
||||
##
|
||||
# Main program
|
||||
run_cli() {
|
||||
mkdir -p ${CLI_DATA}
|
||||
|
||||
# Run CLI
|
||||
docker rm --force cli || true
|
||||
docker run --name cli \
|
||||
docker run \
|
||||
--rm -ti --init \
|
||||
-v ${CLI_DATA}:/data \
|
||||
$DOCKER_ARGS \
|
||||
@ -20,14 +18,7 @@ run_cli() {
|
||||
|
||||
# Jump to root shell
|
||||
if [ $? -eq 10 ]; then
|
||||
sh
|
||||
/bin/ash
|
||||
fi
|
||||
}
|
||||
|
||||
##
|
||||
# Run endless CLI
|
||||
mkdir -p ${CLI_DATA}
|
||||
|
||||
while true; do
|
||||
run_cli
|
||||
done
|
||||
exit
|
||||
|
Loading…
x
Reference in New Issue
Block a user