Skip to content
Snippets Groups Projects
Select Git revision
  • jw_sonar
  • v6.0.0 protected
  • bedran_exercise-list
  • ask-user-to-delete-exercises-on-duplicates
  • update-dependencies
  • main default protected
  • jw_sonar_backup
  • add_route_assignments
  • 6.0.0-dev
  • 5.0.1
  • 5.0.0
  • 4.1.0
  • 4.0.0
  • 3.5.3
  • 3.5.2
  • 3.5.1
  • 3.5.0
  • 3.4.2
  • 3.4.1
  • 3.4.0
  • 3.3.0
  • 3.2.0
  • 3.1.3
  • 3.1.2
  • 3.1.1
  • 3.1.0
  • 3.0.1
  • 3.0.0
28 results

dojobackendapi

  • Clone with SSH
  • Clone with HTTPS
  • DojoBackendAPI

    Development environment

    Env vars

    You can decrypt env var stored in the .env.vault file with the following commands in the ExpressAPI folder:

    > npx dotenv-vault local keys
     environment DOTENV_KEY
     ─────────── ─────────────────────────────────────────────────────────────────────────
     development dotenv://:key_1234@dotenv.local/vault/.env.vault?environment=development
    
    Set DOTENV_KEY on your server
    
    > npx dotenv-vault local decrypt dotenv://:key_1234@dotenv.local/vault/.env.vault?environment=development > .env.development

    The .env.keys file have to be requested to the project maintainers.

    Database

    For development, you can use the docker-compose file in the Resources/DevInfra/ folder.

    docker-compose -f Resources/DevInfra/docker-compose.yml up -d

    This will run a MariaDB database on port 59231 with the following credentials: root:9buz7f312479g6234f1gnioubervw79b8z

    A second container is created with the Adminer tool on port 62394.

    Structure creation and seeding

    The following command will create the database structure and seed it with some exemple data.

    npm run database:deploy:dev