Guest User

Untitled

a guest
Apr 9th, 2020
162
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. status: ## display status of all service of the compose file
  2.     @docker-compose ps --services | sort | while read service; do \
  3.         status=`docker inspect --format='{{.State.Status}}' $$service`; \
  4.         if [ "$$status" = "starting" ]; then \
  5.             color_status="\033[40m"; \
  6.         elif [ "$$status" = "running" ]; then \
  7.             color_status="\e[32m"; \
  8.         else \
  9.             color_status="\e[31m"; \
  10.         fi; \
  11.         echo "$$service: $$color_status $$status\e[39m"; \
  12.     done
RAW Paste Data