#!/usr/bin/env bash MODE="$1" display_usage() { echo "This script takes one arguments." echo -e "\nUsage: ${0} \n" } if [[ "${MODE}" = "help" ]] then display_usage exit 0 fi case "$MODE" in "interactive") echo "Copying $MODE files" cp -r ${QUAYCONF}/init/service/interactive/* /etc/service ;; "batch") echo "Copying $MODE files" cp -r ${QUAYCONF}/init/service/batch/* /etc/service ;; *) echo "Copying all files" cp -r ${QUAYCONF}/init/service/interactive/* /etc/service cp -r ${QUAYCONF}/init/service/batch/* /etc/service ;; esac /sbin/my_init