Skip to content

Commit 3af9355

Browse files
committed
Change .env template name, add Docker health check ot test.yml
1 parent 728c67a commit 3af9355

File tree

4 files changed

+28
-13
lines changed

4 files changed

+28
-13
lines changed
File renamed without changes.

.github/workflows/release.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,16 @@
1-
name: Release
1+
name: Publish release
22
on:
3+
release:
4+
types: [published]
35
workflow_dispatch:
46
inputs:
57
dry-run:
68
type: boolean
79
required: true
810
default: true
9-
release:
10-
types: [published]
1111

1212
jobs:
13-
publish:
14-
name: Publish release to PyPI
13+
release:
1514
runs-on: ${{ matrix.os }}
1615
strategy:
1716
matrix:

.github/workflows/test.yml

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,47 @@
1-
name: Python CI
1+
name: Run test suite
22

33
on: [push, workflow_dispatch]
44

55
jobs:
6-
build:
6+
test:
77
runs-on: ${{ matrix.os }}
88
strategy:
99
matrix:
1010
os: [ubuntu-latest]
11-
python-version: [3.9, 3.13]
12-
splunk-version: ["8.2", "9.4", "latest"]
11+
python-version:
12+
- 3.7
13+
# - 3.9
14+
# - 3.13
15+
splunk-version:
16+
- "8.2"
17+
# - "9.3"
18+
# - "9.4"
19+
# - "latest"
1320
fail-fast: false
1421
steps:
1522
- name: Checkout repo
1623
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
1724
- name: Set up environment variables
18-
run: cp ./.env.template ./.env
25+
run: cp ./.env.test ./.env
1926
- name: Launch Splunk ${{ matrix.splunk-version }}
2027
run: SPLUNK_VERSION=${{ matrix.splunk-version }} docker compose up -d
2128
- name: Set up Python ${{ matrix.python-version }}
2229
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065
2330
with:
2431
python-version: ${{ matrix.python-version }}
2532
- name: Install dependencies
26-
run: type -a python && python --version && python -m pip install . --group dev
33+
run: type -a python && python -m pip install tox
34+
- name: Run Docker health check
35+
# This probably does nothing
36+
run: |
37+
timeout 30s make wait_up
38+
if [ $? -eq 124 ]; then
39+
echo "Splunk failed to start within 30 seconds."
40+
docker compose logs
41+
exit 1
42+
fi
2743
- name: Run test suite
28-
run: type -a python && python --version && python -m tox -e py
44+
run: type -a python && python -m tox -e py
2945
# [BJ] I'll uncomment this step after I finish fiddling
3046
# fossa-scan:
3147
# uses: splunk/oss-scanning-public/.github/workflows/oss-scan.yml@main

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ name = "splunk-sdk"
88
dynamic = ["version"]
99
description = "The Splunk Software Development Kit for Python"
1010
readme = "README.md"
11-
requires-python = ">=3.9.23"
11+
requires-python = ">=3.7.17"
1212
license = { file = "LICENSE" }
1313
authors = [{ name = "Splunk, Inc.", email = "[email protected]" }]
1414
classifiers = [

0 commit comments

Comments
 (0)