| 2. Build Process | 3. Build Tools | 4. Built Artifacts | 5. Tests | 6. Test Tools | 7. Hosted at | 8. Deployed By | 9. Deployed At |
---|---|---|---|---|---|---|---|---|
Location of the Repository | Build Steps | Framework used to accomplish this | Built Artifacts Created and their Locations | Tests to be Run | Test Suite | Artifacts that have passed all tests | Deployment Infrastructure and Configurations | Infrastructure Provider (AWS, Azure) |
The steps above represent the work flow from source code to infrastructure. Our ultimate goal is to have a stable, automated process that can consistently deliver infrastructure.
For the alpha release we are focusing on automating steps 7-9. We work from the assumption that steps 2-6 work and that the artifacts of those steps are available for further processing. The public repositories with the DMC*** names represent the products of steps 2-6 and the hosted locations of step 7. From there, our goal is to allow fast and simple deployment of a stable DMC stack. AWS will be the first infrastructure target followed by GE Internal, Open Stack, and Local (via virtual box).
Future releases will further automate the remaining steps of the process.
View our detailed Deployment Instructions.
Each component of the DMC is hosted on its own instance and the infrastructure from code is orchestrated via Terraform.
Visit each page to get more detailed instructions for the process.
- DigitalMfgCommons/DMCLoadBal
- DigitalMfgCommons/DMCFrontEnd
- DigitalMfgCommons/DMCRestServices
- DigitalMfgCommons/DMCDb
- DigitalMfgCommons/DMCDome
- DigitalMfgCommons/DMCActiveMQ
- DigitalMfgCommons/DMCIdentity
- DigitalMfgCommons/DMCGit
- DigitalMfgCommons/DMCSolr
- DigitalMfgCommons/DMCDeploy
We will be describing deployment on aws public infrastructure. Our goal is to be infrastructure agnostic and will be adding instructions on how to deploy to other providers in the future.
- Gather your AWS credentials.
You will need public and private access keys, as well as access to a PEM file for remote server login. These steps can be found in Setting Up Your Amazon Credentials.
- Set up Terraform on your development environment
- Select the machine you will be working on
- Your local Machine
- A local virtual machine Vagrant box instructions
- A remote AWS development machine
- Your local Machine
- Install Terraform – The Terraform installation guide can be found in /wiki/spaces/DMC/pages/27197443 or at their website https://terraform.io/intro/index.html
- Select the machine you will be working on
- Pull down the appropriate deployment repositories
- For Production – most stable pull from DMCDeploy
- For Development --newest code base pull from DMCDeploy_Dev. This repo is configured to allow for fast deployments and code changes. Also allows for individual deployment of segments of the infrastructure. New features of the stack will not be deployed here.
- git clone git clone https://bitbucket.org/DigitalMfgCommons/dmcdeploy_dev.git
- To remain lean the stack created from DMCDepoly_Dev does not contain by default
- Load Balancers
- Security Zones for each individual instance. All machines are deployed to a single security zone with no access restrictions.
- All machines use the same key pair for ssh
- Automated Testing – This infrastructure will deploy development components such as Build (Bamboo/Jenkins), Automated testing tools (Selenium/ Mocha)
- For Production – most stable pull from DMCDeploy
4. Edit Configuration files – By default, no machines will be created since all the necessary .tf files are commented out. Using your favorite text editor, go through these files and remove the comments (/* at beginning and */ at end) to create the machine corresponding to the file name.
- Open terraform.tfvars using your favorite text editor.
access_key = "your aws key"
secret_key = "your aws secret key"
key_name = "alexTERRA2" << make sure no .pem and make sure the key is configured for the appropriate aws region
key_full_path = "~/Desktop/aws/tf/test/DMCFrontEnd/alexTERRA2.pem" << full path to your pem file including the file
stackPrefix = "alex2" << this prefix will be added to all infrastructure elements created so that your stack can be identified form others
activeMqRootPass = "admin" << the admin root pass for activemq
activeMqUserPass = "user" << the user pass for activemq
stackPrefix = "alexGG" << prefix for the stack to be deployed so multiple stacks can coexist
release = "hot" << will determine which release to pull from 'hot'=master/newest code [for dev always use hot] 'V0.0'=alpha release when available
aws_region = "us-west-2" << will deploy in Oregon region 'us-east-1' will deploy in Virginia
- Open terraform.tfvars using your favorite text editor.
- You should see a stack that contains your selected machines come up. The process should take been 10-15 minutes for a full stack.
In order to bring down the stack you created, use
terraform destroy or manually bring the machines down in Amazon.
If you wish to update your application code read the Detailed Deployment Instructions and follow Deployment Option II.