check for dotenv in scripts

This commit is contained in:
b1ek 2023-03-17 19:02:48 +10:00
parent 513b4c9161
commit 64e780b7af
Signed by: blek
GPG Key ID: 14546221E3595D0C
2 changed files with 14 additions and 0 deletions

7
dev.sh
View File

@ -1,5 +1,12 @@
#!/bin/bash
if [ ! -f .env ]; then
echo "No .env; Please create .env and try again"
exit
fi
. '.env'
cp docker-compose.dev docker-compose.yml
cp Dockerfile.dev Dockerfile

View File

@ -1,5 +1,12 @@
#!/bin/bash
if [ ! -f .env ]; then
echo "No .env; Please create .env and try again"
exit
fi
. '.env'
cp docker-compose.prod docker-compose.yml
cp Dockerfile.prod Dockerfile