Add a script to build and launch the docker container in one step.

This commit is contained in:
Tom Alexander 2023-08-31 15:17:14 -04:00
parent b4170dda1f
commit e8f262727d
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
2 changed files with 14 additions and 0 deletions

View File

@ -19,6 +19,8 @@ docker run --init --rm --publish 3000:3000/tcp org-investigation
```
This launches a server listening on port 3000, so pop open your browser to http://127.0.0.1:3000/ to access the web interface.
(alternatively, you can run the `scripts/launch_docker.bash` script which performs these two steps.)
### No docker
You will need a fully functional rust setup with nightly installed (due to the use of exit_status_error). Then from the root of this repo you can launch the server by running:

12
scripts/launch_docker.bash Executable file
View File

@ -0,0 +1,12 @@
#!/usr/bin/env bash
#
set -euo pipefail
IFS=$'\n\t'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
function main {
make --directory "$DIR/../docker"
exec docker run --init --rm --publish 3000:3000/tcp org-investigation
}
main "${@}"