File size: 233 Bytes
397e650
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
#!/bin/bash -e

# If running the rails server then create or migrate existing database
if [ "${@: -2:1}" == "./bin/rails" ] && [ "${@: -1:1}" == "server" ]; then
  ./bin/rails db:prepare
  ./bin/rails db:seed || true
fi

exec "${@}"