Mercurial > public > ssdt-docker
annotate scripts/import-usps.sh @ 95:01e478158d87 release/v1.1.0
flow: Created branch 'release/v1.1.0'.
author | smith@nwoca.org |
---|---|
date | Mon, 10 Apr 2017 18:26:14 +0100 |
parents | 6f8a77d8d58d |
children | 13751fd2e40a |
rev | line source |
---|---|
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
1 #!/bin/bash |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
2 |
73 | 3 source "$( dirname "${BASH_SOURCE[0]}")/.functions.sh" |
4 | |
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
5 docker-compose stop uspsapp uspsdb |
73 | 6 resetDbVolume uspsdb |
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
7 docker-compose rm -vf uspsapp uspsdb |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
8 |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
9 export IMP_IRN=${IMP_IRN} |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
10 export IMP_URL=${IMP_URL-ftp://username:password@nwoca.org} |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
11 export IMP_PATH=${IMP_PATH} |
45 | 12 export IMP_ANON=${IMP_ANON:--a false} |
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
13 export IMP_EM=${IMP_EM-} |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
14 |
94 | 15 docker-compose -f docker-compose.yml -f /ssdt/compose/preview/import-usps.yml rm -f uspsimport |
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
16 # start import and wait for completion |
94 | 17 docker-compose -f docker-compose.yml -f /ssdt/compose/preview/import-usps.yml up uspsimport | tee uspsimport.log |
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
18 # remove temporary container |
94 | 19 docker-compose -f docker-compose.yml -f /ssdt/compose/preview/import-usps.yml rm -f uspsimport |
44
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
20 # start application |
e5ba33051de7
add scripts and compose file for importing from server
Dave smith <smith@nwoca.org>
parents:
diff
changeset
|
21 docker-compose up -d uspsapp |