Skip to content

Latest commit

 

History

History
41 lines (30 loc) · 2.07 KB

INSTALL.md

File metadata and controls

41 lines (30 loc) · 2.07 KB

Installing the app

  • Make sure musicbrainz db and the required database tables are present.
  • Follow https://github.com/metabrainz/musicbrainz-docker to install the required containers and db dumps.
  • Rename the .env.example to .env, to set the RUN_MODE to development.
  • Rename config/development.example.toml to config/development.toml and config/production.example.toml to config/production.toml.
  • Ensure yq is installed, for using configs in the sql scripts.
  • After ensuring musicbrainz_db is running on port 5432, Run the script init_db.sh in scripts dir.
  • In config/development.toml file, create a sentry rust project, enter your sentry project DSN (Data Source Name) in the url key's value.
  • Get the Internet Archive API accesskey and secret from here (requires sign in). Paste them in config/development.toml file [wayback_machine_api]'s variables myaccesskey and mysecret.

There are 2 methods to run the program:

  1. Build the project and run.
    • Make sure rust is installed.
    •   cargo build &&
        ./target/debug/melba
  2. Use the Dockerfile
    • Note that the container has to run in the same network as musicbrainz db network bridge.
      docker-compose -f docker/docker-compose.dev.yml up --build

Setting up Prometheus, Grafana

  1. On your browser, go to localhost:3000, to access grafana. Login using admin as username and password.

    img.png

  2. Go to Dashboard. Select melba-dashboard.

    img.png

  3. If the Rust app metrics panel shows no data, just click on the refresh icon on top right corner.

    img.png

  4. To edit, right-click on the panel and select edit option. You can edit the panel, and save the generated json in grafana/dashboards/metrics-dashboard.json.

    img.png