The service for managing the canonical list of training providers for Department for Education (DfE) and, more specifically, Becoming a teacher (BAT).
This project depends on:
This project uses asdf, refer to .tool-versions for the actual versions in use. Use the following to install the required tools:
# The first time
brew install asdf # Mac-specific
asdf plugin add ruby
asdf plugin add nodejs
asdf plugin add postgres
# To install (or update, following a change to .tool-versions)
asdf installWhen installing the pg gem, bundle changes directory outside of this
project directory, causing it lose track of which version of postgres has
been selected in the project's .tool-versions file. To ensure the pg gem
installs correctly, you'll want to set the version of postgres that asdf
will use:
# Temporarily set the version of postgres to use to build the pg gem
ASDF_POSTGRES_VERSION=17.2 bundle installsolargraph is bundled as part of the development dependencies. You need to set it up for your editor, and then run this command to index your local bundle (re-run if/when we install new dependencies and you want completion):
bin/bundle exec yard gemsYou'll also need to configure your editor's solargraph plugin to
useBundler:
+ "solargraph.useBundler": true,We keep track of architecture decisions in Architecture Decision Records (ADRs).
We use rladr to generate the boilerplate for new records:
bin/bundle exec rladr new titleTo run the application locally:
- Run
bin/setup --skip-serverto setup the app - Run
bin/devto launch the app on http://localhost:1025
To run the linters:
bin/lintTo set up the example data for the app run the following
rails example_data:generateTo set up local authentication using personas add the following to your environment file:
# .env.local
SIGN_IN_METHOD=persona-
Sign up at OS Data Hub using your
education.gov.ukemail. -
When prompted:
- Select Public Sector Plan
- Set Organisation to
Department for Education
-
Wait for your account to be approved by the Department for Education account holder.
-
Once approved, go to API projects. You’ll see projects for each environment:
-
Copy the API key from the relevant project and add it to your environment file:
# .env.local ORDNANCE_SURVEY_API_KEY=dev-api-key-here