Corsair-Ranch / TACT

Travel Accommodations and Coordination Technology - Hack the Ranch 2023
2 stars 1 forks source link

TACT: Travel Accommodations and Coordination Technology

This project is created for Hack the Ranch May 2023

Updated July 2023

Team Members

Problem Statement

Build an automated tool that calculates PACAF O&M dollars per head count for the exercise.

Tool should include

Objectives

How to use

docker-compose build
docker-compose up

Using PM2 for Development

If using Docker Desktop

ONLY if using Docker CLI, run

docker-compose up db
docker stop tact-server-1
docker ps

Next,

npm install pm2 -g
./start.sh

Warning If you have a db_data_volume folder in the top directory you may need to remove it if you run into issues with the database not seeding properly, or other server issues.

Keycloak Local Config

Keycloak is included as a Docker container, but the container does not save your user data so it needs to be recreated each time the container spins-up. Until we find a way around it, it's recommended to spin-up a local version of the Keycloak container and leave it running instead of using "docker-compose up". Here is the local command to keep this container running to avoid recreating users all the time (replace the X's with your home directory):

docker run --name mykeycloak -p 8180:8180 \ -e KEYCLOAK_ADMIN=kcadmin -e KEYCLOAK_ADMIN_PASSWORD=kcpasswd \ -e KEYCLOAK_IMPORT=/opt/keycloak/data/import/ \ -v "/XXXXX/XXXXX/XXXXX/TACT/Client/keycloak-export":/opt/keycloak/data/import \ quay.io/keycloak/keycloak:latest \ start-dev --http-port=8180 --import-realm

Keycloak User Account Creation

So as long as you run the Keycloak container locally and keep it running, you won't lose your users. It's recommended to create a COCOM Planner user and at least one Wing Planner account.