-
Create a volume directory
$ mkdir -p /opt/ab2d
-
Note that this directory acts as a shared volume for the API and worker containers
-
Remove comments in the docker-compose.yml to set db ports
ports: - "5432:5432"
-
Run postgress and localstack locally using Docker
$ docker-compose up db localstack
Worker Setup
- Select Run/Debug Configuration > Edit Configurations > add configuration (+) > Spring Boot
- In Main Class select gov.cms.ab2d.worker.SpringBootApp
- Go to 1Password and search for 'AB2D Local Env Variables'. Use the configs in the note for the Environment Variables field
- Run the configuration
API Setup 6. Select Run/Debug Configuration > Edit Configurations > add configuration (+) > Spring Boot 7. In Main Class select gov.cms.ab2d.api.SpringBootApp 8. Go to 1Password and search for 'AB2D Local Env Variables'. Use the configs in the note for the Environment Variables field 9. Run the configuration
Anyone committing to this repo must use the pre-commit hook to lower the likelihood that secrets will be exposed.
You can install pre-commit using the MacOS package manager Homebrew:
brew install pre-commit
Other installation options can be found in the pre-commit documentation.
Run the following command to install the gitleaks hook:
pre-commit install
This will download and install the pre-commit hooks specified in .pre-commit-config.yaml
.