-
Notifications
You must be signed in to change notification settings - Fork 1
60 lines (52 loc) · 1.53 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Build Splunk App
on:
push:
branches:
- "master"
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
pull_request:
branches:
- "master"
jobs:
# Package App
package:
name: Package
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
# semantic-release won't trigger a tagged build if this is not set false
persist-credentials: false
# Our add-on contains Python code, so we need to install Python in the container
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Package Splunk App with CLI
run: |
pwd
ls -la
cd ${GITHUB_WORKSPACE}
wget https://download.splunk.com/misc/packaging-toolkit/splunk-packaging-toolkit-1.0.1.tar.gz
pip install splunk-packaging-toolkit-1.0.1.tar.gz
mkdir dist
slim validate sekoia.io/
slim package sekoia.io/ -o dist
- uses: splunk/appinspect-cli-action@v1
with:
app_path: 'dist/*.tar.gz'
result_file: 'dist/appinspect-report.json'
included_tags: cloud
- name: upload-appinspect-report
uses: actions/upload-artifact@v2
if: always()
with:
name: appinspect-report.json
path: dist/appinspect-report.json
- name: Upload package as an artifact
uses: actions/upload-artifact@v2
with:
name: package-splunkbase
path: dist/*.tar.gz