WITH VIRTUAL MACHINES - SEA · One of Several NSIDC Development Teams Dataset Production Visualizations Dataset Access Python JavaScript A Bit of Ruby ... VAGRANT USES VIRTUALBOX
Post on 26-Aug-2020
3 Views
Preview:
Transcript
VIRTUAL GOODNESSWITH
VIRTUAL MACHINESKevin Beam
Jeff BraucherMatt Savoie
Hannah Wilcox
Supports research into Earth's cryosphereManages and distributes scientific dataCreates tools for data accessSupports data usersPerforms scientific researchPerforms public education and outreachDistributes more than 500 cryospheric data sets
ABOUT USOne of Several NSIDC Development TeamsDataset ProductionVisualizationsDataset AccessPythonJavaScriptA Bit of RubyWe are hiring!Have we mentioned we're hiring?
THE CHALLENGE
ARCTIC CHANGEShowcase Remote Sensing DatasetsFocus on the Arctic RegionLong Time-Series DatasetsAccessible to Non-Specialists
VIRTUAL MACHINES:OVERVIEW
ISOLATION OF APPLICATIONFrom resource contentionFrom server failuresFrom maintenanceFrom people failures
DEVELOPER CONTROLDifferent version of commonly installed softwareUncommon/specialty softwareQuick turnaround... as long as devs can figure it outLess hassle for sys admins... as long as devs can figure it out
SAME ENVIRONMENT EVERYWHERE
EVERYWHERE = {LOCAL, INTEGRATION, STAGING, QA, BLUE}
VAGRANT AND
VIRTUALBOX
VAGRANT USES VIRTUALBOX OUT OF THE BOX
VIRTUALBOX PROVIDES VIRTUAL MACHINES
VMWARE, AWS, HYPER-V PROVIDE VIRTUAL MACHINES
VAGRANT USES THESE AND MORE AS PLUGINS
EXAMPLE. LET'S:Define a VMCreate and run a VMLogin to the VMStop the VM
PUPPET
WHY DO I NEED A PUPPET?AUTOMATION!Create users, directories, etcInstall packages (apt-get install)Ensure things are runningDeclarative
BEST OF ALLVagrant can tell Puppet to provision the box after it's been created
EXAMPLE. LET'S:Install nginxMake sure it's running
FABRIC
WHAT'S FABRIC?Fabric is a simple, Pythonic tool for remote execution and
deployment.
WHAT DO WE USE IT FOR?Deploy our application to the target machine(s)
Make sure it's restarted / running
> fab deploy_application HOSTNAME
> fab restart_application HOSTNAME
FABRIC HAS TWO MAIN PARTS:Define tasksRun remote commands
EXAMPLE USAGE:@taskdef deploy(): undeploy()
sudo('mkdir -p /var/www/maps-of-arctic-change') sudo('chown -R vagrant:vagrant /var/www/maps-of-arctic-change')
rsync_project(local_dir=os.path.join(PROJECT_DIR, 'dist/mac'), remote_dir='/var/www/maps-of-arctic-change')
restart_gunicorn()
OTHER ALTERNATIVESPuppet!Capistrano (Ruby on Rails)Language / Platform Specific Tools
Build your own private cloud.
VAGRANT + VSPHERE
vSphere is just another vagrant provider
vSphere runs VMs in the datacenter
(actual NSIDC datacenter pictured)
THINGS YOU WILL NEED :vagrant-vsphere plugin (available on github)server hostname for vSphere APIusername and password for vSphereRSA key for vagrant user in vSphere template
WHAT ELSE DOES VSPHERE DO?
provides load balancing and failoverscales horizontally across physical machinesprovides templates for new VMsmanages names and IP addresses
apps.nsidc.org
DYNECT : CLOUD DNS
puts applications in their own sub-domainprovides a rich DNS management APIcan be integrated with vSphereallows teams to create DNS aliasesenables blue / green deployment
Follow the VM!
BLUE / GREEN DEPLOYMENT
ACTUALLY, WE DO IT LIKE THIS :
Q & A
top related