Categorygithub.com/adevinta/vulnerability-db-api

# README

Vulnerability Database API

REST API for the Vulnerability Database.

Visit the API documentation page here.

For running the component locally, you need to have access to the vulnerability-db repo, as it's the one that contains the DB schema and migrations. For running the component locally, clone and run at the root of the repo the following:

go install ./...
cd ../vulnerability-db/db && source postgres-start.sh && cd -
cd ../vulnerability-db/db && source flyway-migrate.sh && cd -
vulnerability-db-api -c ../_resources/config/local.toml

Docker execute

Those are the variables you have to use:

VariableDescriptionSample
LOG_LEVELerror
PG_HOSTDatabase hostlocalhost
PG_NAMEDatabase namevulnerabilitydb
PG_USERDatabase uservulnerabilitydb
PG_PASSWORDDatabase passwordvulnerabilitydb
PG_PORTDatabase port5432
PG_SSLMODEOne of these (disable,allow,prefer,require,verify-ca,verify-full)disable
PG_HOST_READRead replica database hostlocalhost
PG_NAME_READRead replica Database namevulnerabilitydb
PG_USER_READRead replica Database uservulnerabilitydb
PG_PASSWORD_READRead replica Database passwordvulnerabilitydb
PG_PORT_READRead replica Database port5432
PG_SSLMODE_READOne of these (disable,allow,prefer,require,verify-ca,verify-full)disable
PG_CA_B64A base64 encoded CA certificate
docker build . -t vdba

# Use the default config.toml customized with env variables.
docker run --env-file ./local.env vdba

# Use custom config.toml
docker run -v `pwd`/custom.toml:/app/config.toml vdba

# Packages

No description provided by the author
No description provided by the author
No description provided by the author