Alfresco Software Provisioning Kit Enzo Rivello Alfresco Senior DevOps Engineer
Enzo Rivello 5 months of Alfresco Devops Activiti Team, Dev-Products, TAA Before, Playstation DevOps Lead Developer of https://github.com/Alfresco/alfresco-spk https://github.com/Alfresco/vagrant-packer-plugin Follow https://www.alfresco.com/blogs/devops https://github.com/enzor
Tool and Automation Team Automate all the things Automation across the borders Technologies Departments Integration with Building systems Evangelization
Design|Run|Integrate Alfresco stacks Alfresco SPK Design|Run|Integrate Alfresco stacks
Agenda The challenges Alfresco Installation Alfresco SPK Wrapping up
The Challenges
The Challenges The hosting choice Myriads of Cloud Providers Myriads of Orchestration Tools Provisioning challenges Distributed architectures Articulated provisioning process Alfresco Installer limitations
Solutions Alfresco Installation Customizable/Configurable Modular Versionable Portable
Solutions Alfresco SPK Define/reuse a stack Test a stack locally Create Official Alfresco Images (Marketplace AMIs, Vagrant Boxes, …) Create Custom Images Integrate CI tools with image building process (release pipeline integration) Integrate orchestration tools to bootstrap immutable images (go live)
Alfresco Installation
4x <full provisioning> Instance Lifecycle Stack Genesis Stack Engine 4 IPs ID ID Solr 2 Share1 Share 2 1 Root Image (distro) Alfresco Image (tiered) <provision> <bootstrap> 4x <full provisioning>
<full provisioning> Instance Lifecycle Stack Genesis Stack Engine 4 IPs ID ID Solr 2 Share1 Share 2 1 Root Image (distro) Alfresco Image (tiered) <provision> <bootstrap> <full provisioning>
Chef Alfresco (beyond Chef Installer) Component-based: repo, share, solr, aos and more Supports 3 run modes (full-provisioning, provisioning-only, bootstrap-only) Any Alfresco configuration can be customised Can run continuously (install on top of an installation) Downloads artifacts (VS Alfresco Installer monolithic installation) Open Source, 68 releases, 11 contributors - https://github.com/Alfresco/chef-alfresco Haproxy, nginx
Alfresco SPK and the Vagrant Packer Plugin
Alfresco SPK Operations Choose a stack Browse stack examples provided by the SPK Run/Tweak Spin up a stack locally using Virtualbox or VmWare Build Images Define Alfresco immutable images Integrate Run the CI and orchestration tool of your choice
SPK Library - components Instance template(s) (JSON), which contain Chef Alfresco Attributes Image building configuration (Packer) Local run (Vagrant) Vagrantfile to define the stack and reference instance template(s) Packer Plugin common configuration Local Vagrant run common configuration We already provide configuration for Alfresco AllInOne and Enterprise
Instance template - components { "name": ”...", "alfresco" : { "components" : <alfresco_components> } Allinone components ["haproxy","nginx","tomcat","transform","repo","share","solr","mysql"] Share components ["haproxy","nginx","tomcat","transform","repo","share"] Solr components ["haproxy","tomcat”,"repo","transform","solr"]
Run your stack Vagrant.configure("2") do |config| # Source Image configuration config.vm.box = "<vagrant_box_name>" config.vm.box_url = "<vagrant_box_url>” # Vagrant up configuration instance_template = JSON.parse("<instance_template_json_path>") config.vm.provision "chef_solo" do |chef| chef.json = instance_template chef.recipe_url = "<chef_alfresco_tar_url>" instance_template['run_list'].each do |recipe| chef.add_recipe recipe end End
Build your stack Vagrant.configure("2") do |config| # SPK minimal configuration config.packer_build.cookbooks_url = “<cookbooks_url/path>” config.packer_build.instance_templates = [“<instance_template_url/path>”] End
Try it yourself! # Clone SPK repo git clone https://github.com/Alfresco/alfresco-spk # Install Vagrant Packer Plugin vagrant plugin install vagrant-packer-plugin cd alfresco-spk/stacks/community-allinone # Or build your own Vagrantfile and instance template(s) # Run the stack locally vagrant up # Build immutable images (default to Vagrantbox) vagrant packer-build
Wrapping up
Choose an SPK stack and play with Vagrantfile and instance templates Go Live – Zero to Hero [Go Live] [Image Build] vagrant packer-build [Tweak and Local run] Vagrant up [Configuration] Choose an SPK stack and play with Vagrantfile and instance templates
Infrastructure as Code delivered Revamped installation experience Component-based installation Controls provisioning and bootstrap phases https://github.com/Alfresco/chef-alfresco Reusable instance templates/images Integration with cloud providers and orchestration tools https://github.com/Alfresco/alfresco-spk SPK
SPK in Alfresco AWS Marketplace AMIs Alfresco 5.1 Enterprise Allinone Alfresco 5.1 Enterprise Allinone + Records Management Alfresco Activiti Enterprise Online Trials Offline Trials / Sales Demos Alfresco Benchmark Alfresco Infrastructure Alfresco Cloud
Roadmap Support additional Linux/Unix OSes Publish Alfresco Vagrant boxes for existing instance templates allinone, share, solr, … Integrate with Alfresco SDK Docker Integration (build only) Improved docs for advanced Chef users Publish chef-alfresco into Chef Supermarket Product capabilities, timeframes and features are subject to change and should not be viewed as Alfresco commitments.
Thanks!