DEVELOPMENT ENVIRONMENT

~liljamo/deck-builder

ref: dba81d38792caad88bb3daae4e2e7a9c50e31dcd deck-builder/sdbapi/dev-launch.sh -rwxr-xr-x 455 bytes
dba81d38Jonni Liljamo Move Cfg things to a new mod 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/bash

function confirm() {
  echo -n "$@ [y/N]: "
    read -e answer
    for response in y Y
    do
        if [ "_$answer" == "_$response" ]
        then
            return 0
        fi
    done

    # default to no
    return 1
}

confirm reset containers? && sudo docker compose down
confirm reset database? && sudo docker volume rm sdbapi_apidb_data

confirm rebuild api? && sudo docker compose build

confirm launch? && sudo docker compose up