Skip to content

joinmilo/dev

Repository files navigation

Milo Dev

All services started from a single repository

Keep in mind this repository is for local development only and is not meant to be deployed on any production environment!

Requirements

  1. Docker
  2. Docker Compose

How to run it?

  1. Clone the repository:
git clone https://github.com/joinmilo/dev --recursive milo.dev
  1. Shared folders: We are using shared folders to enable live code reloading. Without this, Docker Compose will not start: - Windows/MacOS: Add the cloned milo.dev directory to Docker shared directories (Preferences -> Resources -> File sharing). - Windows/MacOS: Make sure that in Docker preferences you have dedicated at least 5 GB of memory (Preferences -> Resources -> Advanced). - Linux: No action required, sharing already enabled and memory for Docker engine is not limited.

  2. Go to the cloned directory:

cd milo.dev
  1. Copy the .env file from the example :
cp .env.example .env
  1. In the .env file you will see the variable MILO_LOCATION_KEY. Ask for MILO_LOCATION_KEY or create your own Bing Maps Key (see Bing Maps Integration)

  2. In the .env file you will see the variable MILO_CAPTCHA_SECRET. Ask for MILO_CAPTCHA_SECRET or create your own hCaptcha secret (see hCaptcha docs)

  3. Ask for firebase-credentials.json or create your own Firebase credential file (see Firebase Docs)

  4. Copy firebase-credentials.json to server:

cp  /path/to/your/firebase-credentials.json server/src/main/resources/credentials/firebase-credentials.json
  1. Copy media files to server storage
mkdir server/.storage
cp -a media/. server/.storage
  1. In order to have a local db running, ask for SQL dump and place it into /db

  2. Build the stack:

docker compose build --no-cache
  1. Run the application:
docker compose up

In case of server development you should run the server within the IDE and not within docker compose. In that case you can use the scale flag, e.g.:

docker compose up --scale server=0

Tools and URLs

After building and running the application following URLs are exposed:

GraphQL Playground

For testing the API you can reach the playground here: http://localhost:8011/gui

Media content

In order to retrieve any media content there are the following endpoints to retrieve them:

Specification and data model

The folder specs contains the datamodel and is a Modelio project.

To open the project open Modelio and switch the workspace to specs.

How to update the subprojects to the newest versions?

This repository contains newest stable versions. When new release appear, pull new version of this repository. In order to update all of them to their newest versions, run:

git submodule update --remote

During the development there might be changes in existing changelog files. Therefore the whole database need to be purged. To setup a clean database you have to purge the volume before starting the docker-comppose:

docker compose down -v

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •