Overview
This article is in progress and covers our first attempt at putting the Bonsai Framework infrastructure on the cloud. We have the following final targets,
- Confluence with Supporting CICD Systems and Integration
- Tomcat in Docker inside of LXD
- Tomcat in Cloud Foundry inside of LXD
We have covered first set of steps on Path to Cloud (document later) up to CICD.
Using the in progress parts of the cloud article we have settled on the following,
Component | Selection | Notes | Top 3 Reasons |
---|---|---|---|
... | Puppet | ||
Virtualization Cloud Provider | Azure | Will also try Amazon later for proper comparison. | Clearer documentation to start. |
Source Control for Code | Bitbucket selecting GitHub | DevOps Repository created with Frank as the main manager and Roderick as the Administrator. | |
Distributed Operating System for Containers | None | Confluence is not yet. | |
Operating Virtualization | LXD | Cost Savings, Transportable, Isolation. |
Virtualization Cloud Provider
Here details necessary to size with Azure Canadian Calculator.
Software Requirements
Ongoing systems that will always be up,
Software | Average Memory for our Use Case | # of Users | Space | CPU |
---|---|---|---|---|
Apache Web Server | 200MB | 1.44GB | ||
Confluence | 1.6GB(to be tuned) | 10.79GB | ||
PostGreSQL | 543.79MB | 455.74MB | ||
Puppet Server | ||||
Artifactory |
Calculations
This was what I got as best bang for the buck given we can use LXD,
- West US 2 is ~$20.00/month cheaper than other regions for what we need,
- A1
- Basic
- 1 Core
- 1.75 GB RAM
- 40 GB Disk
- $21.71/month or $0.29/hour
Option A
Free Options
There are various free tiers on Azure of which we want to use,
Service Item | Sizing | Limits | Purpose |
---|---|---|---|
Virtual Network | 50 free virtual network. | Create private networks with full control over IP addresses, DNS servers, security rules, and traffic flows. Virtual network to on-premises using a VPN tunnel, or connect using ExpressRoute service. | |
Azure Active Directory | 500,000 directory objects and single sign-n for up to 10 apps per user. | Nice to have - can we make Confluence hook up with Google SSO? | |
App Service | F1 Instance | Lab, try Tomcat and Docker. | |
Scheduler | 3,600 job executions per month. | To run automated backups. | |
Automation | 500 minutes per month of job run time. | IT automation. | |
Azure Monitor | Free while in public preview | ||
Traffic Manager | DNS routing failover and basic traffic health check |
Monitoring Container Growth
Peak
Date | sql | app | web |
---|---|---|---|
Feb 08, 2017 | 543.79MB | 1.6GB | 200MB |
Feb 28,2017 | 501.11MB | 1.72GB | 301.45MB |
Mar 08, 2017 | 493.27MB | 1.76GB | 311.74MB |
Server Notes for bfgroupdiag538 (Move into Separate File Later)
Next Steps
- Automated Backups Moved to Offsite
- Add Google Analytics
- Remove no robots and start adding into Google and Forums
- Setup monitoring to focused on measuring performance to resize
- If it makes sense resize to lower costs (2 smaller servers instead of the 1 big)
April 12, 2017
- Disabled Automatic Updates
March 26, 2017
- Secured Apache
February 23, 2017
- Added Google Analytics
February 22, 2017
- Resized the zpool to 20GB because containers were throwing out of space errors
- Turned off robots.txt (prevents Search Engines from calling)
- Submitted www.bonsaiframework.com to Google Search Engine (Search Console)
- Added Balsamiq plug-in through Confluence web console
February 08, 2017
- Server was resized to fit confluence $51.56/month
- Memory increased to 3.5GB
- Virtual Server = bonsaifw02host
- Built using 16.04 LTS
- Fully migrated and www.bonsaiframework.com is now live
- Next steps Working on backup solution
January 24, 2017
We created first iteration straight migration VMs.
- Resource Group =
- Virtual Server = bonsaifw01host
- Built using Ubuntu 16.10 (we'll switch back to LTS for iteration 2)
- 3 LXD Tiers created (all using LXD dynamic IPs)
- NAT setup for port 80 host to web server
- Azure Native Firewall (NSG) port 80 Configured
- Confluence Installed and ready for first run to migrate the data.
January 17, 2017
- Roderick gave Tin access
- Tin created virtual machine using Ubuntu 16.04 LTS per research with setupadmin
- Roderick logged in added fail2ban and then rest of BonsaiFramework Setup
Installed LXD with following,
Name of the storage backend to use (dir or zfs) [default=zfs]: Create a new ZFS pool (yes/no) [default=yes]? Name of the new ZFS pool [default=lxd]: Would you like to use an existing block device (yes/no) [default=no]? Size in GB of the new loop device (1GB minimum) [default=15]: Would you like LXD to be available over the network (yes/no) [default=no]? Would you like stale cached images to be updated automatically (yes/no) [default=yes]? Would you like to create a new network bridge (yes/no) [default=yes]? What should the new bridge be called [default=lxdbr0]? What IPv4 subnet should be used (CIDR notation, "auto" or "none") [default=auto]? What IPv6 subnet should be used (CIDR notation, "auto" or "none") [default=auto]? LXD has been successfully configured.