Skip to content

Commit 2632b74

Browse files
authored
Enable Nightly Builds (#125)
* attempt at nightly builds from master branches * limit to master branch * that wasn't right * test dispatch * use workflow dispatch instead * try https * try eventextractor with ssh key * add username * remove from envlist and style * fix .iml * remove .idea/ and add to gitignore
1 parent ea94fc4 commit 2632b74

File tree

5 files changed

+47
-19
lines changed

5 files changed

+47
-19
lines changed

.github/workflows/nightly.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: nightly
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: '0 5 * * *'
7+
8+
jobs:
9+
nightly:
10+
11+
runs-on: ubuntu-latest
12+
strategy:
13+
matrix:
14+
python: [3.5, 3.6, 3.7, 3.8]
15+
16+
steps:
17+
- uses: actions/checkout@v2
18+
- name: Setup Python
19+
uses: actions/setup-python@v1
20+
with:
21+
python-version: ${{ matrix.python }}
22+
- name: Setup SSH Keys and known_hosts
23+
env:
24+
SSH_AUTH_SOCK: /tmp/ssh_agent.sock
25+
run: |
26+
mkdir -p ~/.ssh
27+
ssh-keyscan github.com >> ~/.ssh/known_hosts
28+
ssh-agent -a $SSH_AUTH_SOCK > /dev/null
29+
ssh-add - <<< "${{ secrets.C42_EVENT_EXTRACTOR_PRIVATE_DEPLOY_KEY }}"
30+
- name: Install tox
31+
run: pip install tox==3.17.1
32+
- name: Run Unit tests
33+
env:
34+
SSH_AUTH_SOCK: /tmp/ssh_agent.sock
35+
run: tox -e nightly # Run tox using latest master branch from py42/c42eventextractor

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ __pycache__/
1010
# C extensions
1111
*.so
1212

13+
# IDE files
14+
.idea
15+
1316
# Distribution / packaging
1417
.Python
1518
build/

.idea/.gitignore

Whitespace-only changes.

.idea/code42cli.iml

Lines changed: 0 additions & 19 deletions
This file was deleted.

tox.ini

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,12 @@ commands = sphinx-build -W -b html -d {envtmpdir}/doctress docs {envtmpdir}/html
3131
deps = pre-commit
3232
skip_install = true
3333
commands = pre-commit run --all-files --show-diff-on-failure
34+
35+
36+
[testenv:nightly]
37+
deps =
38+
pytest == 4.6.11
39+
pytest-mock == 2.0.0
40+
pytest-cov == 2.10.0
41+
git+https://github.com/code42/py42.git@master#egg=py42
42+
git+ssh://git@github.com/code42/c42eventextractor.git@master#egg=c42eventextractor

0 commit comments

Comments
 (0)