scripts/update-motd.d/50-ansible

25 lines
561 B
Bash
Executable File

#!/bin/sh
# .. vim: foldmarker=[[[,]]]:foldmethod=marker
# {{ ansible_managed | comment }}
# Colors definition [[[
BLACK='\033[49;30m'
BLACKB='\033[49;90m'
RED='\033[0;31m'
REDB='\033[1;31m'
GREEN='\033[0;32m'
YELLOW='\033[0;33m'
BLUE='\033[94;49m'
MAGENTA='\033[0;35m'
CYAN='\033[36;49m'
WHITE='\033[0;37m'
BOLD='\033[1m'
RESET='\033[0m'
# ]]]
if [ -d "/etc/ansible/facts.d" ] ; then
printf "${BLACKB}%80s${RESET}\\n" | tr ' ' -
printf '%b' " ${CYAN}This system is managed by ${BOLD}Ansible${RESET}${CYAN}, manual changes will be lost${RESET}\\n"
fi