Skip to content
This repository has been archived by the owner on Dec 19, 2023. It is now read-only.

Commit

Permalink
sync for policy (#1)
Browse files Browse the repository at this point in the history
Co-authored-by: Addon Factory template <[email protected]>
  • Loading branch information
Ryan Faircloth and Addon Factory template authored Aug 21, 2020
1 parent c43e2fc commit 373998a
Show file tree
Hide file tree
Showing 10 changed files with 65 additions and 1,673 deletions.
27 changes: 8 additions & 19 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,45 +197,34 @@ orbs:
pip install git+https://github.com/pixelb/crudini
mkdir test-results
- run:
name: Splunk up
name: Splunk Testing
command: |
# Start Splunk
ls -l deps/build/addonfactory_test_matrix_splunk/splunk_matrix.conf
export SPLUNK_VERSION=$(crudini --get deps/build/addonfactory_test_matrix_splunk/splunk_matrix.conf "<<parameters.splunk_version>>" VERSION)
export SPLUNK_APP_ID=$(crudini --get package/default/app.conf id name)
docker-compose -f docker-compose-ci.yml build
docker-compose -f docker-compose-ci.yml up -d splunk
until docker-compose -f docker-compose-ci.yml logs splunk | grep "Ansible playbook complete" ; do sleep 1; done
- run:
name: Run diag
when: always
command: |
# Run a Splunk Diag
mkdir /tmp/diag
diag=$(docker-compose -f docker-compose-ci.yml exec splunk sudo -u splunk /opt/splunk/bin/splunk diag | grep "Splunk diagnosis file created" | sed -n 's/.* \(\/.*\.gz\)/\1/p')
docker-compose -f docker-compose-ci.yml exec splunk sudo chmod +r ${diag//[$'\t\r\n']}
docker cp project_splunk_1:${diag//[$'\t\r\n']} /tmp/diag
- run:
name: Check btool
when: always
command: |
# Check with btool
docker-compose -f docker-compose-ci.yml exec splunk sudo /opt/splunk/bin/splunk cmd btool check
docker-compose -f docker-compose-ci.yml up -d splunk
sleep 30
- run:
name: Test
when: always
command: |
# Run the tests
docker-compose -f docker-compose-ci.yml up --abort-on-container-exit test
no_output_timeout: 1h
- run:
name: collect results
when: always
command: |
# Collect Results
docker volume ls
docker container create --name dummy \
-v project_results:/work/test-results \
registry.access.redhat.com/ubi7/ubi
docker cp dummy:/work/test-results/test.xml test-results/
docker cp dummy:/work/test-results/cim-compliance-report.md test-results/
docker cp dummy:/work/test-results/cim-compliance-report.md test-results/ || true
no_output_timeout: 2h
jobs:
aio:
resource_class: xlarge
Expand Down
16 changes: 0 additions & 16 deletions .dependabot/config.yml

This file was deleted.

33 changes: 33 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
target-branch: "develop"
schedule:
interval: "daily"
- package-ecosystem: "gitsubmodule"
directory: "/"
target-branch: "develop"
schedule:
interval: "daily"
- package-ecosystem: "gitsubmodule"
directory: "/deps/build"
target-branch: "develop"
schedule:
interval: "daily"
- package-ecosystem: "gitsubmodule"
directory: "/deps/apps"
target-branch: "develop"
schedule:
interval: "daily"
- package-ecosystem: "pip"
directory: "/"
target-branch: "develop"
schedule:
interval: "daily"
- package-ecosystem: "pip"
directory: "/tests"
target-branch: "develop"
schedule:
interval: "daily"
16 changes: 16 additions & 0 deletions .github/workflows/reuse.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
##
## SPDX-FileCopyrightText: 2020 Splunk, Inc. <[email protected]>
## SPDX-License-Identifier: LicenseRef-Splunk-1-2020
##
##
name: REUSE Compliance Check

on: [push, pull_request]

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: REUSE Compliance Check
uses: fsfe/[email protected]
3 changes: 2 additions & 1 deletion pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ norecursedirs = .git .venv venv build deps tests/deps node_modules package
addopts = -v --tb=long
--splunk-data-generator=tests/data
--splunk-type=docker
-n 15
--sc4s-host=sc4s
-n 5
--keepalive
filterwarnings =
ignore::DeprecationWarning
2 changes: 1 addition & 1 deletion requirements_dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
## SPDX-License-Identifier: LicenseRef-Splunk-1-2020
##
-r tests/requirements.txt
pytest-splunk-addon[docker]>=1.1.0
pytest-splunk-addon[docker]>=1.3.0
reuse
Loading

0 comments on commit 373998a

Please sign in to comment.