You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
441 B
20 lines
441 B
#!/bin/bash |
|
|
|
DOCKER_CONFIG_DIRECTORY="/home/jonathan/.dotfiles/docker/web/" |
|
|
|
if [ ! -z "$1" ]; then |
|
|
|
version="$1" |
|
|
|
if [ "$(whoami)" == "root" ]; then |
|
cd "$DOCKER_CONFIG_DIRECTORY" |
|
docker-compose down |
|
sed "s/%version%/$version/" php/Dockerfile.sample > php/Dockerfile |
|
docker-compose up --build -d |
|
else |
|
gksudo $0 "$version" |
|
fi |
|
else |
|
version="$(echo -e "5.6\n7.0\n7.1\n7.2\n7.3" | rofi -dmenu -p "PHP Version")" |
|
$0 "$version" |
|
fi
|
|
|