DEVELOPMENT ENVIRONMENT

~liljamo/deck-builder

ref: c5058564df22e37812957f45970ca7b90a37f270 deck-builder/.archived/sdbapi/dev-launch-alpine.sh -rwxr-xr-x 471 bytes
c5058564Jonni Liljamo feat(client(nix)): add rust-analyzer to devshell 1 year, 9 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/bash

export COMPOSE_PROJECT_NAME=sdbapi

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? && docker-compose down
confirm reset database? && docker volume rm sdbapi_apidb_data

confirm rebuild api? && docker-compose build

confirm launch? && docker-compose up