Project

General

Profile

Continuous Delivery and Testing » History » Version 5

Luke Murphey, 02/25/2017 11: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 5 Luke Murphey
19 3 Luke Murphey
Should this be done using:
20 3 Luke Murphey
# The build script?
21 5 Luke Murphey
## Pros: Could hide password using secure variable; can be done in a single line; password can be globally in environment variables
22 5 Luke Murphey
## Cons: requires the build script as a material; requires ant on all agents
23 3 Luke Murphey
# Direct commands?
24 4 Luke Murphey
# Straight copying?
25 5 Luke Murphey
26 5 Luke Murphey
Using the build script:
27 5 Luke Murphey
Pros:
28 5 Luke Murphey
# Could hide password using secure variable
29 5 Luke Murphey
# Can be done in a single line
30 5 Luke Murphey
# Password can be globally in environment variables
31 5 Luke Murphey
# Could bump Splunk too
32 5 Luke Murphey
33 5 Luke Murphey
Cons:
34 5 Luke Murphey
# Requires downloading the build script as a material
35 5 Luke Murphey
# Requires ant on the agents