Skip to content

An implementation for FIWARE Orion and Cygnus on AWS.

License

AGPL-3.0, MIT-0 licenses found

Licenses found

AGPL-3.0
LICENSE
MIT-0
LICENSE.MIT-0
Notifications You must be signed in to change notification settings

aws-samples/fiware-orion-on-aws

FIWARE: Orion and Cygnus on AWS

This guide will help you to deploy Fiware's Orion and Cygnus (optional) components into a serverless architecture.

What does this repository include?

  1. An AWS CDK project in charge of provisioning the basic infrastructure with a VPC Network, Security Groups and two managed Databases, one Amazon Aurora Serverless (PostgreSql) and one Amazon DocumentDB. These are represented in the following stacks:

    • Network Stack
    • DocumentDB Stack
    • Aurora Stack
    • Fiware Stack (new stack replacing the deprecated docker ecs-integration)

What doesn't this repository include?

Besides WAF configuration to allow IP based access, this repository does not include any additional security mechanisms. However, we do recommend to read the security considerations from Fiware and enable SSL communication. For the later, please read create-https-listener and how to enable this in CDK

Architecture

Architecture

How to use it?

1. Requirements

Instal node v18.16.1 or greater.

2. Infrastructure

1.1 Create an AWS profile is recommended if you do not have it.

3. Configuring settings

Use the settings.ts file to configure your deployment. You can delete/comment the cygnus attribute if you only want to deploy Fiware Orion. You can also choose to deploy the 'fiware/orion' image or the 'fiware/orion-ld' from docker hub by configuring the orionLD attribute.

Additionally in the Orion construct you can add environmental variables, for more information check the following links:

4. Deployer script

The infrastructure is deployed by this bash script:

./deployer.sh <YOUR_AWS_PROFILE>

After the deployment is completed, you can see these services running in you AWS account.

AWS Service Description
AWS Fargate Containers for Orion and Cygnus
Application Load Balancer (ALB) Load Balancer for Orion and Cygnus web api.
Amazon DocumentDB Database for Orion
Amazon Aurora Serverless Database for Cygnus
AWS WAF Web Application Firewall for the ALB. *

NOTE: WAF rules for the ALBs can be changed, please see this reference.

5. Demo

Follow the demo from the published blog: How to build smart cities with FIWARE Orion Context Broker and Cygnus on AWS

6. Load Testing

Loadtest for FIWARE Components provides load test for FIWARE Orion-LD

7. Clean up

If you need to clean up the resources, please follow steps below.

[WARN] All data will be deleted by this step.

npm run cdk destroy -- --all --profile <YOUR_AWS_PROFILE>

8. Known Issues

8.1 DocumentDB vs MongoDB

8.2 Docker ECS integration deprecation

Docker Compose's integration for ECS and ACI is retiring in November 2023. from https://docs.docker.com/cloud/ecs-integration/

You can upgrade your current existing deployment by following these steps:

IMPORTANT: we recommend you to do a full backup of the database services Aurora RDS and Amazon DocumentDB before continuing.

  1. Edit the settings.ts file to configure your ECS services and WAF settings.
  2. Delete the cygnus and orion stacks from the AWS Console Cloudformation, be sure to select the region used to deploy.
  3. Execute the deployer in your terminal: ./deployer.sh <YOUR_AWS_PROFILE>
  4. You will get a new endpoint for Orion, FiwareStack.orionservice...: http://....elb.amazonaws.com/
  5. If you deployed with Cygnus, you can subscribe to it in the new URL: <http://cygnus.fiware:5055/notify>

License

This project is licensed under the GPL v3 License. See the LICENSE file.This library is licensed under the GPL v3 and the MIT-0 License. See the LICENSE.MIT-0 file.

About

An implementation for FIWARE Orion and Cygnus on AWS.

Resources

License

AGPL-3.0, MIT-0 licenses found

Licenses found

AGPL-3.0
LICENSE
MIT-0
LICENSE.MIT-0

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published