Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

61 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Deploying Voting App with Atmosly

Welcome to the Atmosly deployment guide! This README will walk you through the steps to deploy Voting app on our platform.

Before we begin:

  1. Here is a quick introduction of Atmosly.
  2. Here is where you can learn about common terminologies that we will be using throughout this document. Through this document, we will be deploying Voting application on Atmosly. Listed here is a brief of all the steps we will be following to successfully deploy the application.

About the Voting App

GitHub URL - https://github.com/atmosly/voting-app-atmosly.git.

This application consists of five microservices -

  • Vote (python) - from where end user would cast a vote
  • Result (react) - where the results of the voting are stored
  • Worker (dot net)
  • Postgresql
  • Redis

Prerequisites

  • An account on Atmosly
    Follow the steps here to sign up on Atmosly.
  • A cloud account integrated
    Follow the steps here to integrate your AWS account.

PLEASE NOTE: we only have support of AWS on the platform right now.

  • A cluster ready on Atmosly Follow the steps here to create a cluster on Atmosly.

Setup

We have an open source project available for the Voting App.

What are Projects:

Projects is an application blueprint on Atmosly where we define basic details for an application.
Projects module have three elements:

  1. Applicaton services
  2. DataSource services
  3. Environment Variables

You can find more details about the Project module here.

To make Voting App project on Atmosly:

Step 1 :

For the application services, you will need to click on the "+" icon in Applications and add Vote microservice as per screenshot below. Adding Vote Microservice:

alt text

For all other application microservices, i.e. Result and Worker, follow a similar structure as with the Vote microservice. Repo would be considered service's repo.

Step 2:

For the database, you will need to click on the "+" icon in Data Sources and add PostgreSQL and Redis individually.

alt text

Once you have added both application and datasource services, it would look like this:

alt text

Now, to manage dependency in between applications, you can use environment variables to tell the, for example, Website Service where to find the Database Service.

Step 3:

a. Click on the Edit Environment Variable button.

alt text

You have two choices for adding environment variables:

  1. Importing/ selecting the .env file from GitHub branch - by clicking on the Import button.
  2. Manually adding it by clicking the Add button - in the case where you would like to manually define your variables or add to the list of environment variables, you can also add your variable manually.

We will import our variables for the services:

  1. Vote microservice variables - Click on Import button and select 'main' as branch and select .env.vote as the file and click on Proceed.
  2. Result microservices variables - Click on Import button and select 'main' as branch and select .env.result as the file and click on Proceed.
  3. Worker microservice variables - Click on Import button and select 'main' as branch and select .env.worker as the file and click on Proceed.

The final screen after the environment variables have been added would look something like this -

Vote:

alt text

Worker:

alt text

Result:

alt text

Great! Our basic setup is completed. Now, let's create an environment for deploying the application on EKS cluster.

Deployment

By this time you have:

  1. Successfully integrated a cloud account
  2. Successfully created a cluster
  3. Have a Voting App project

To create environment, follow the steps mentioned here with the information required.

Application Services:

Please note, you will need to pass the following details to deploy Voting App - Voting app (for result, vote and worker services)

  1. Branch:
    • result: main
    • vote: main
    • worker: main
  2. Dockerfile Path:
    • result: result/Dockerfile
    • vote: vote/Dockerfile
    • worker: worker/Dockerfile
  3. Build Context:
    • result:
    • vote:
    • worker:
  4. port:
    • result: 80
    • vote: 80
    • worker: 80
  5. endpoint type:
    • result: public load balancer
    • vote: public load balancer
    • worker: cluster IP
  6. min-max CPU : 500m-1000m for all application services
  7. min-max memory : 1000mi-2000mi for all application services

Database Services:

Please note, you will need to pass the following details to deploy the database services for the Voting App (Postgres and Redis)

  1. Type:

    • Postgres: Self Managed
    • Redis: Self Managed
  2. Version:

    • Postgres: any
    • Redis: any
  3. Nodegroup:

    • Postgres: default
    • Redis: default
  4. Storage Size:

    • Postgres: 10GB
    • Redis: 5GB
  5. Username , Password & Dataname:

    • Postgres: any
    • Redis: any

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages