Example of Multi Cloud Application Design and Deployment with Micronaut
APACHE-2.0 License
A sample application that demonstrates how to structure an application for Multi Cloud development and deployment.
The app
subproject contains the application code with no Cloud specific dependencies or configuration.
The aws
subproject depends on the app
project and introduces configuration (defined in aws/src/main/resources/application-ec2.yml
) and dependencies (defined in aws/build.gradle
) that integrate the application with services of AWS:
The oci
subproject depends on the app
project and introduces configuration (defined in oci/src/main/resources/application-oraclecloud.yml
) and dependencies (defined in oci/build.gradle
) that integrate the application with services of Oracle Cloud:
The oci-infra
subproject contains terraform scripts to deploy oci
subproject to the OCI. It uses OCI CLI for authentication.
To run it you have perform the following steps:
terraform.tfvars
with necessary information.is_free_tier
to false
in apm.tf
and database.tf
../gradlew shadowJar
in the root of the project.terraform init
inside oci-infra
subproject.terraform apply
inside oci-infra
subproject.After successful build the application URL will be written to the terminal window.
You can destroy the Cloud resources when you are done by running terraform destroy
.
The aws-infra
subproject builds and deploys aws
subproject to the AWS. It uses AWS CDK to achieve this.
To run it you have perform the following steps:
cdk bootstrap
inside aws-infra
subproject.cdk deploy
inside aws-infra
subproject.After successful build the application URL will be written to the terminal window.
You can destroy the Cloud resources when you are done by running cdk destroy
.