Skip to content

DEFRA/cap-xml

Repository files navigation

CAP-XML Services

Build statusQuality Gate StatusCoverage

Synopsis

This project provides CAP XML services through the use of AWS Lambda.

Environment Variables

name description required default notes
stage AWS stage yes
CPX_REGION AWS region yes
CPX_DB_USERNAME Database username yes
CPX_DB_PASSWORD Database password yes
CPX_DB_NAME Database name yes
CPX_DB_HOST Database host yes
CPX_AGW_URL API Gateway URL yes
CPX_REDIS_HOST Redis/Elasticache host yes
CPX_REDIS_PORT Redis/Elasticache port yes
CPX_REDIS_TLS Redis/Elasticache tls yes
CPX_METEOALARM_API_URL Meteoalarm url yes
CPX_METEOALARM_API_USERNAME Meteoalarm username yes
CPX_METEOALARM_API_PASSWORD Meteoalarm password yes
CPX_METEOALARM_DISABLE Meteoalarm toggle no

Prerequisites

  • Node.js 22 or higher

Installing

npm ci --ignore-scripts

Running Unit Tests

npm test

Local Development

Local Development Prerequisites

  • Docker 28.02 or above
  • Docker Compose 2.34 or above

Containerisation is used to provide developers with the ability to develop, run and debug AWS Lambda functions without reliance on deployment to AWS infrastructure. This replaces Serverless local function invocation following Serverless V.3 reaching end of support and a decision not to upgrade to Serverless V.4.

Local Development Options

Contributing to this project

If you have an idea you'd like to contribute please log an issue.

All contributions should be submitted via a pull request.

License

Copyright, Environment Agency. Licensed under Creative Commons BY 4.0

About

CAP XML services

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors