Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Automate your development environment with Jira and Saltstack

1,501 views

Published on

Presentation by Wojciech from NetworkedAssets for the Atlassian User Group Lower Silesia on April 20th, 2016 about how to automatically manage development environments with simple Jira tickets and Saltstack.

Published in: Software
  • Be the first to comment

Automate your development environment with Jira and Saltstack

  1. 1. Automate your development environments with JIRA and SaltStack
  2. 2. IT Automation 20.04.2016 IT Process Automation Cloud OrchestrationInfrastructure Provisioning Automation scripts Application Release Automation Network Automation Business Process Automation Workload automation Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  3. 3. IT Automation 20.04.2016 IT Process Automation Cloud OrchestrationInfrastructure Provisioning Automation scripts Application Release Automation Network Automation Business Process Automation Workload automation Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  4. 4. Software Configuration Management • Code describing shape of configured objects 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  5. 5. Software Configuration Management • Code describing shape of configured objects • Declarative 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  6. 6. Software Configuration Management • Code describing shape of configured objects • Declarative • Additional abstraction layer 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  7. 7. Software Configuration Management • Code describing shape of configured objects • Declarative • Additional abstraction layer • Handles dependencies and execution order 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  8. 8. Software Configuration Management Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław • Code describing shape of configured objects • Declarative • Additional abstraction layer • Handles dependencies and execution order 20.04.2016
  9. 9. Automation and processes Let’s assume that at this point: • Configuration Management solution is implemented 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  10. 10. Automation and processes Let’s assume that at this point: • Configuration Management solution is implemented • Every part of infrastructure is defined by code 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  11. 11. Automation and processes Let’s assume that at this point: • Configuration Management solution is implemented • Every part of infrastructure is defined by code • Code is stored within repository 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  12. 12. Automation and processes Let’s assume that at this point: • Configuration Management solution is implemented • Every part of infrastructure is defined by code • Code is stored within repository • As we push new code, our infrastructure changes 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  13. 13. Automation and processes Let’s assume that at this point: • Configuration Management solution is implemented • Every part of infrastructure is defined by code • Code is stored within repository • As we push new code, our infrastructure changes Can we automate it even further? 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  14. 14. Let me tell you a story a developer goes to a sysadmin… 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  15. 15. Let me tell you a story a developer goes to a sysadmin… 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  16. 16. Nope. It never goes this way Here goes true version of the story… 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  17. 17. Nope. It never goes this way Here goes true version of the story… Since we’ll need a ticket anyway… let’s make the most of it. 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  18. 18. JIRA webhooks • Simple interface to interact with other applications { "transition": { "workflowId": 10401, "workflowName": "SI: Cloud orchestration workflow", "transitionId": 11, "transitionName": "Provision", "from_status": "Ready to build", "to_status": "Provisioning" }, "comment": "", "user": { "self": "http://ww-dev-01.networkedassets.local/jira/rest/api/2/user?username=ww", "name": "ww", "key": "ww", "emailAddress": "wwrobewski@networkedassets.org", "displayName": "ww", "active": true, "timeZone": "UTC" }, "issue": { "id": "10401", "self": "http://ww-dev-01.networkedassets.local/jira/rest/api/2/issue/10401", "key": "SI-9", "fields": { "issuetype": { "self": "http://ww-dev-01.networkedassets.local/jira/rest/api/2/issuetype/10200", "id": "10200", "description": "", "iconUrl": "http://ww-dev- 01.networkedassets.local/jira/secure/viewavatar?size=xsmall&avatarId=10300&avatarType=issuetype", "name": "Order", "subtask": false, "avatarId": 10300 }, 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  19. 19. JIRA webhooks • Simple interface to interact with other applications • On execution of mapped action, sends HTTP POST request { "transition": { "workflowId": 10401, "workflowName": "SI: Cloud orchestration workflow", "transitionId": 11, "transitionName": "Provision", "from_status": "Ready to build", "to_status": "Provisioning" }, "comment": "", "user": { "self": "http://ww-dev-01.networkedassets.local/jira/rest/api/2/user?username=ww", "name": "ww", "key": "ww", "emailAddress": "wwrobewski@networkedassets.org", "displayName": "ww", "active": true, "timeZone": "UTC" }, "issue": { "id": "10401", "self": "http://ww-dev-01.networkedassets.local/jira/rest/api/2/issue/10401", "key": "SI-9", "fields": { "issuetype": { "self": "http://ww-dev-01.networkedassets.local/jira/rest/api/2/issuetype/10200", "id": "10200", "description": "", "iconUrl": "http://ww-dev- 01.networkedassets.local/jira/secure/viewavatar?size=xsmall&avatarId=10300&avatarType=issuetype", "name": "Order", "subtask": false, "avatarId": 10300 }, 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  20. 20. Bringing Salt to workflow one ticket == one environment • Provisioning and Orchestration introduced as process stages • Decommission workflow • Error handling: negative flow • Use webhooks to call other applications APIs 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  21. 21. JIRA + SaltStack • JIRA and SaltStack are tools made for whole different purpose • Operate on different sets of objects • They won’t understand each other …unless we provide them a translator. 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  22. 22. Crystalized the middleman What it does? – Collects webhook calls – Translates objects and data – Manages jobs – Validates results 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  23. 23. Crystalized the middleman What it does? – Collects webhook calls – Translates objects and data – Manages jobs – Validates results What it is? – A lightweight application written in python – Based on flask framework 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  24. 24. DEMO TIME! 20.04.2016Automate your development environments with JIRA and Saltstack, Atlassian User Group LS, Wrocław
  25. 25. Project View Activity
  26. 26. Create „Order”
  27. 27. „Order” Draft status
  28. 28. Workflow view
  29. 29. Provisioning…
  30. 30. Provisioning Openstack view
  31. 31. It’s running!
  32. 32. Job reports as comments
  33. 33. Reconfigure Add Salt States
  34. 34. Orchestrate!
  35. 35. Orchestration Job Report
  36. 36. Our Confluence server is running. Well done!
  37. 37. THANK YOU FOR YOUR ATTENTION! Wojciech Wróblewski wwroblewski@networkedassets.org www.networkedassets.com EOF

×