Skip to content

cabinetoffice/GCGS-Central-Digital-Platform

Repository files navigation

GCGS Central Digital Platform

Development

Import the project to your favourite IDE to build and run tests from there.

Alternatively, use the dotnet command or the following make targets to build and run tests:

make build
make test

Any dotnet tools used by the project are installed locally.

The database is one of the services defined in Docker Compose. It can be started on its own and used with the IDE setup. First, containers need to be built:

make build-docker

The database can be then started together with migrations:

docker compose up -d db organisation-information-migrations

Configuration

The application is mostly configured to start with a fresh repository checkout. Secrets that are not safe to be committed to the repository are managed with the Secrets Manager:

  • OneLogin:Authority
  • OneLogin:ClientId
  • OneLogin:PrivateKey

These can be set within the IDE, or with the dotnet command:

dotnet user-secrets set --project Frontend/CO.CDP.OrganisationApp/CO.CDP.OrganisationApp.csproj OneLogin:Authority "https://oidc.example.com"
dotnet user-secrets set --project Frontend/CO.CDP.OrganisationApp/CO.CDP.OrganisationApp.csproj OneLogin:ClientId "client-id"
dotnet user-secrets set --project Frontend/CO.CDP.OrganisationApp/CO.CDP.OrganisationApp.csproj OneLogin:PrivateKey "-----BEGIN RSA PRIVATE KEY-----
SECRET KEY
-----END RSA PRIVATE KEY-----"

Never commit secrets to the repository.

Documentation

For technical documentation see Docs.

Design Decisions

For important design decisions that were made as the project evolved see the decision log.

Docker

While local development is done within our IDE of choice, the Docker configuration is provided to conveniently start all the services at once.

Building containers

First, we need to build all Docker containers:

make build-docker

Configuration

Run make compose.override.yml to generate the default configuration.

One login details need to be provided to the organisation-app in compose.override.yml as environment variables:

  • OneLogin__Authority
  • OneLogin__ClientId
  • OneLogin__PrivateKey

Starting services

To start all Docker services:

make up

The first run creates compose.override.yml that can be used to override service configuration locally.

By default service and application ports are mapped as follows:

In order to prevent selected service(s) from starting, configure the number of replicate in compose.override.yml to 0:

# ...
  person:
    deploy:
      replicas: 0
    # ...

Stop all Docker services:

make down

To only start the database and apply migrations run:

make db

About

The Central Digital Platform (CDP) that is being developed to support the new procurement regime.

Resources

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published