Cloudify has plugins for connecting to several major cloud service providers. In this tutorial, we will make Cloudify deploy a simple blueprint with the Amazon Web Services (AWS). Under the hood, Cloudify invokes Boto, the AWS Python
SDK providing API to interact with AWS services like Lambda functions, RDS and IAM.
In this tutorial, we will use a Docker image of the premium version of the Cloudify Manager to deploy a Hello World server on an AWS EC2 t.micro machine.
Table of Contents:
Note: This tutorial is tested with Cloudify 5.0.0
sudo docker run --name cfy_manager_local -d --restart unless-stopped -v /sys/fs/cgroup:/sys/fs/cgroup:ro --tmpfs /run --tmpfs /run/lock --security-opt seccomp:unconfined --cap-add SYS_ADMIN -p 80:80 -p 8000:8000 cloudifyplatform/premium-cloudify-manager-aio:latest
localhost:80. Default credentials are admin-admin. To activate the premium version of the Cloudify Manager, insert your license.
yamlfiles you find in the Cloudify Github repository.
AWSSDKis an outdated plugin we use only to run this old example.
Create the AWS secrets providing the credentials of your AWS account:
Running the example
Go to “Local Blueprints” menu and click the Upload button.
Insert “https://github.com/cloudify-cosmo/cloudify-hello-world-example/archive/master.zip” in the blueprint URL field.
In the blueprint YAML file select “aws.yaml”.
Note: you may have to wait for one minute and a half and then see an
An unexpected error has occurred: ESOCKETTIMEDOUTerror. Unfortunately, this behaviour happens even though the blueprint was successfully uploaded. After the error, wait for another thirty seconds for the new blueprint to appear in the list of all blueprints.
In the blueprints table, click on the name of the blueprint.
Click on the Create Deployment button.
Type the name of the blueprint in the deployment name field.
Type the region (e.g, “eu-central-1") in the aws_region_name field.
Scroll down to the deployments table, click the hamburger icon on the right and select Install and then Execute. The install workflow will take a few minutes to complete.
Check the website
Tear down the deployment
To remove the docker with the Cloudify Manager, run
sudo docker rm -f cfy_manager_local cfy_manager_local
In this tutorial, we used the premium edition of the Cloudify Manager to deploy a simple web server on AWS. In next tutorials, we will start using the premium edition to develop and deploy more complex cloud applications on AWS.