Building the project
See web/README.md for instructions on building and running the Angular front-end app.
A Makefile is provided with the following targets:
dep: Download and setup project dependencies to the
build: Compile the project. Emitted executables are located in the
bindirectory by default.
run: run the main server executable.
test: run test suite using
clean: Remove all files generated during the build.
clean-deps: Remove all files generated by
For ease of deployment, a docker-compose file can be found in the deploy subdirectory along with all files to build docker images for the webservers and database.
Before deploying, you must fill in all
sample.env files with the proper values and save them as
You can launch the app without further configuration via the
docker-compose up command from the deploy directory.
Upon first launch, the database will be initialized by execution the scripts in
configs/sql. The database files will be saved to
deploy/database/data/ and will be kept between restarts unless explicitly deleted.
If not using docker-compose, you must define the following environment variables for the application to work:
$MYSQL_USERNAME: The username to use for your app (Please don't use the
$MYSQL_PASSWORD: The password for user
$MYSQL_HOST: Hostname or IP address of your MariaDB server
$MYSQL_DATABASE: Database name for the app
docker.errors.DockerException: Error while fetching server API version: ('Connection aborted.', ConnectionRefusedError(111, 'Connection refused'))
- Make sure the docker daemon is running. You can start it by running
systemctl start dockeras a privileged user.
Database schema is incorrect
- You can delete the
deploy/database/datadirectory and the database will be rebuilt from the scripts in
configs/sql. You will lose a data stored in the database.
make distcleanwill delete that subdirectory
Application container is not up to date with the repo's contents
- This can be caused by changes to the
Dockerfileor initialization scripts, or by old artifacts being cached by docker.
- First, you can try rebuilding the containers with
docker-compose up --build.
- If this doesn't work, you should delete the saved containers before running the
docker container ls -aand look for entries that have the one of the following values in the
Imagecolumn and note the
inm5151_glitchfix_goserverfor the Go app
inm5151_glitchfix_webserverfor the Webserver and Angular app
inm5151_glitchfix_databasefor the Mariadb database server
- Remove the containers with
docker container rm <Container ID...>
WARNING: Found orphan containers
- Launching the containers with
docker-compose up --remove-orphanswill delete orphan containers and remove this warning.
Rebuild only the front-end container
sudo docker-compose up —force-recreate —no-deps webproxy
- Back-end (rest api)