I want to preserve colors of docker exec command. The only way I found is to use script command like so
docker exec <container_name> script -q -c "./spiral migrate:status" /dev/null
The problem is that my containers are alpine and there is no script
command by default. How to install it?
One way I found is to install apk add util-linux
. But it takes 350 Mb, just makes not sense of using alpine then.
How to install only one script command? Is there other workarounds to keep the colors?
Just realized that command is basically compiled executable. So the workaround would be to get it from once installed util-linux, and place in all my containers.
0 Answers