Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
executable file 19 lines (12 sloc) 591 Bytes
#!/bin/bash
# STOP CONTAINERS
echo "PostgreSQL container is being stopped..."
docker rm -f codingexpercise-postgres || true
echo "Redis container is being stopped..."
docker rm -f codingexpercise-redis || true
# START CONTAINERS
echo "PostgreSQL container is being started..."
docker run --name codingexpercise-postgres -d -p 5432:5432 -e POSTGRES_PASSWORD=123qwe -e POSTGRES_USER=root -e POSTGRES_DB=codingexpercise postgres
echo "Redis container is being started..."
docker run --name codingexpercise-redis -d -p 6379:6379 redis
echo "All containers have been started successfully."