Continuous Delivery and Testing » History » Version 9
Luke Murphey, 03/04/2017 07:55 PM
1 | 1 | Luke Murphey | h1. Continuous Delivery and Testing |
---|---|---|---|
2 | 1 | Luke Murphey | |
3 | 1 | Luke Murphey | You can use a continuous integration tool to automate testing and deploying your Splunk apps. This will allow you to: |
4 | 1 | Luke Murphey | |
5 | 1 | Luke Murphey | # Test your app on several platforms and versions of Splunk automatically (or with a click of a button) |
6 | 1 | Luke Murphey | # Easily build clean and consistent copies of your app (avoids the possible corrupt builds made on Developer hosts) |
7 | 1 | Luke Murphey | # Deploy the app to your test and production hosts with a single click |
8 | 2 | Luke Murphey | |
9 | 2 | Luke Murphey | Some notes: |
10 | 2 | Luke Murphey | To use a created package (spl or tar.gz), make sure to: |
11 | 2 | Luke Murphey | |
12 | 2 | Luke Murphey | * Make a fetch artifact step |
13 | 2 | Luke Murphey | * Set the fetch as a file, not a directory (https://groups.google.com/forum/#!searchin/go-cd/gocd$20fetch$20zip$20artifact$20%7Csort:relevance/go-cd/Ja5lBT6bpRA/A0ojaSRqBwAJ) |
14 | 3 | Luke Murphey | |
15 | 5 | Luke Murphey | Need to create a minimal account for installing apps with the following capabilities per (https://answers.splunk.com/answers/67843/capability-to-install-app.html): |
16 | 5 | Luke Murphey | * rest_apps_management |
17 | 5 | Luke Murphey | * admin_all_objects |
18 | 9 | Luke Murphey | * restart_splunkd (to restart Splunk) |
19 | 5 | Luke Murphey | |
20 | 7 | Luke Murphey | You might need to add the user "go" to the "splunk" group: |
21 | 7 | Luke Murphey | |
22 | 7 | Luke Murphey | <pre> |
23 | 7 | Luke Murphey | sudo usermod -G splunk go |
24 | 7 | Luke Murphey | </pre> |
25 | 6 | Luke Murphey | |
26 | 3 | Luke Murphey | Should this be done using: |
27 | 3 | Luke Murphey | # The build script? |
28 | 5 | Luke Murphey | ## Pros: Could hide password using secure variable; can be done in a single line; password can be globally in environment variables |
29 | 5 | Luke Murphey | ## Cons: requires the build script as a material; requires ant on all agents |
30 | 3 | Luke Murphey | # Direct commands? |
31 | 4 | Luke Murphey | # Straight copying? |
32 | 5 | Luke Murphey | |
33 | 5 | Luke Murphey | Using the build script: |
34 | 5 | Luke Murphey | Pros: |
35 | 5 | Luke Murphey | # Could hide password using secure variable |
36 | 5 | Luke Murphey | # Can be done in a single line |
37 | 5 | Luke Murphey | # Password can be globally in environment variables |
38 | 5 | Luke Murphey | # Could bump Splunk too |
39 | 5 | Luke Murphey | |
40 | 5 | Luke Murphey | Cons: |
41 | 5 | Luke Murphey | # Requires downloading the build script as a material |
42 | 5 | Luke Murphey | # Requires ant on the agents |