Skip to content
This repository was archived by the owner on Feb 18, 2025. It is now read-only.

Commit bb4e86a

Browse files
author
Brandon McNama
authored
Initial Commit (#1)
1 parent 7c6eb12 commit bb4e86a

27 files changed

+2093
-0
lines changed

.github/workflows/ci.yml

+128
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
name: CI
2+
3+
on:
4+
- push
5+
- pull_request
6+
7+
jobs:
8+
lint:
9+
name: Lint
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v2
14+
- name: Setup Python
15+
uses: actions/setup-python@v2
16+
with:
17+
python-version: '3.8'
18+
- name: Setup Poetry
19+
uses: abatilo/[email protected]
20+
with:
21+
poetry-version: '1.1.3'
22+
- name: Setup Ruby
23+
uses: actions/setup-ruby@v1
24+
with:
25+
ruby-version: '2.7'
26+
- name: Restore dependencies
27+
uses: actions/cache@v2
28+
with:
29+
path: |
30+
vendor
31+
.venv
32+
key: "build-v1-${{ runner.os }}-${{ hashFiles('poetry.lock', 'Gemfile.lock')}}"
33+
restore-keys: |
34+
build-v1-${{ runner.os }}-${{ hashFiles('poetry.lock', 'Gemfile.lock')}}
35+
build-v1-${{ runner.os }}-
36+
build-v1-
37+
- name: Install dependencies
38+
run: >
39+
bundle install --frozen --jobs 2 --path vendor/bundle --clean &&
40+
poetry config virtualenvs.in-project true &&
41+
poetry install --remove-untracked
42+
- name: Run pre-commit
43+
run: >
44+
poetry run pre-commit install --install-hooks &&
45+
poetry run pre-commit run --all-files
46+
47+
kitchen-docker:
48+
name: "Run Test Kitchen on Linux"
49+
needs: lint
50+
runs-on: ubuntu-latest
51+
steps:
52+
- name: Checkout code
53+
uses: actions/checkout@v2
54+
- name: Setup Python
55+
uses: actions/setup-python@v2
56+
with:
57+
python-version: '3.8'
58+
- name: Setup Poetry
59+
uses: abatilo/[email protected]
60+
with:
61+
poetry-version: '1.1.3'
62+
- name: Setup Ruby
63+
uses: actions/setup-ruby@v1
64+
with:
65+
ruby-version: '2.7'
66+
- name: Restore dependencies
67+
uses: actions/cache@v2
68+
with:
69+
path: |
70+
vendor
71+
.venv
72+
key: "build-v1-${{ runner.os }}-${{ hashFiles('poetry.lock', 'Gemfile.lock')}}"
73+
restore-keys: |
74+
build-v1-${{ runner.os }}-${{ hashFiles('poetry.lock', 'Gemfile.lock')}}
75+
build-v1-${{ runner.os }}-
76+
build-v1-
77+
- name: Install dependencies
78+
run: >
79+
bundle install --frozen --jobs 2 --path vendor/bundle --clean &&
80+
poetry config virtualenvs.in-project true &&
81+
poetry install --remove-untracked
82+
# Can't run in parallel because of the hax required to get kitchen-ansible
83+
# working with single roles
84+
- name: Run Test Kitchen
85+
run: >
86+
poetry run bundle exec kitchen test linux
87+
88+
kitchen-macos:
89+
name: "Run Test Kitchen on MacOS"
90+
needs: lint
91+
runs-on:
92+
- macos-10.15
93+
steps:
94+
- name: Checkout code
95+
uses: actions/checkout@v2
96+
- name: Setup Python
97+
uses: actions/setup-python@v2
98+
with:
99+
python-version: '3.8'
100+
- name: Setup Poetry
101+
uses: abatilo/[email protected]
102+
with:
103+
poetry-version: '1.1.3'
104+
- name: Setup Ruby
105+
uses: actions/setup-ruby@v1
106+
with:
107+
ruby-version: '2.7'
108+
- name: Restore dependencies
109+
uses: actions/cache@v2
110+
with:
111+
path: |
112+
vendor
113+
.venv
114+
key: "build-v1-${{ runner.os }}-${{ hashFiles('poetry.lock', 'Gemfile.lock')}}"
115+
restore-keys: |
116+
build-v1-${{ runner.os }}-${{ hashFiles('poetry.lock', 'Gemfile.lock')}}
117+
build-v1-${{ runner.os }}-
118+
build-v1-
119+
- name: Install dependencies
120+
run: >
121+
bundle install --frozen --jobs 2 --path vendor/bundle --clean &&
122+
poetry config virtualenvs.in-project true &&
123+
poetry install --remove-untracked &&
124+
brew install docker
125+
- name: Run Test Kitchen
126+
shell: /bin/zsh {0}
127+
run: >
128+
poetry run bundle exec kitchen test darwin

.gitignore

+207
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,207 @@
1+
# Created by https://www.toptal.com/developers/gitignore/api/ruby,python
2+
# Edit at https://www.toptal.com/developers/gitignore?templates=ruby,python
3+
4+
### Python ###
5+
# Byte-compiled / optimized / DLL files
6+
__pycache__/
7+
*.py[cod]
8+
*$py.class
9+
10+
# C extensions
11+
*.so
12+
13+
# Distribution / packaging
14+
.Python
15+
build/
16+
develop-eggs/
17+
dist/
18+
downloads/
19+
eggs/
20+
.eggs/
21+
lib/
22+
lib64/
23+
parts/
24+
sdist/
25+
var/
26+
wheels/
27+
pip-wheel-metadata/
28+
share/python-wheels/
29+
*.egg-info/
30+
.installed.cfg
31+
*.egg
32+
MANIFEST
33+
34+
# PyInstaller
35+
# Usually these files are written by a python script from a template
36+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
37+
*.manifest
38+
*.spec
39+
40+
# Installer logs
41+
pip-log.txt
42+
pip-delete-this-directory.txt
43+
44+
# Unit test / coverage reports
45+
htmlcov/
46+
.tox/
47+
.nox/
48+
.coverage
49+
.coverage.*
50+
.cache
51+
nosetests.xml
52+
coverage.xml
53+
*.cover
54+
*.py,cover
55+
.hypothesis/
56+
.pytest_cache/
57+
pytestdebug.log
58+
59+
# Translations
60+
*.mo
61+
*.pot
62+
63+
# Django stuff:
64+
*.log
65+
local_settings.py
66+
db.sqlite3
67+
db.sqlite3-journal
68+
69+
# Flask stuff:
70+
instance/
71+
.webassets-cache
72+
73+
# Scrapy stuff:
74+
.scrapy
75+
76+
# Sphinx documentation
77+
docs/_build/
78+
doc/_build/
79+
80+
# PyBuilder
81+
target/
82+
83+
# Jupyter Notebook
84+
.ipynb_checkpoints
85+
86+
# IPython
87+
profile_default/
88+
ipython_config.py
89+
90+
# pyenv
91+
.python-version
92+
93+
# pipenv
94+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
95+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
96+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
97+
# install all needed dependencies.
98+
#Pipfile.lock
99+
100+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
101+
__pypackages__/
102+
103+
# Celery stuff
104+
celerybeat-schedule
105+
celerybeat.pid
106+
107+
# SageMath parsed files
108+
*.sage.py
109+
110+
# Environments
111+
.env
112+
.venv
113+
env/
114+
venv/
115+
ENV/
116+
env.bak/
117+
venv.bak/
118+
pythonenv*
119+
120+
# Spyder project settings
121+
.spyderproject
122+
.spyproject
123+
124+
# Rope project settings
125+
.ropeproject
126+
127+
# mkdocs documentation
128+
/site
129+
130+
# mypy
131+
.mypy_cache/
132+
.dmypy.json
133+
dmypy.json
134+
135+
# Pyre type checker
136+
.pyre/
137+
138+
# pytype static type analyzer
139+
.pytype/
140+
141+
# profiling data
142+
.prof
143+
144+
### Ruby ###
145+
*.gem
146+
*.rbc
147+
/.config
148+
/coverage/
149+
/InstalledFiles
150+
/pkg/
151+
/spec/reports/
152+
/spec/examples.txt
153+
/test/tmp/
154+
/test/version_tmp/
155+
/tmp/
156+
157+
# Used by dotenv library to load environment variables.
158+
# .env
159+
160+
# Ignore Byebug command history file.
161+
.byebug_history
162+
163+
## Specific to RubyMotion:
164+
.dat*
165+
.repl_history
166+
*.bridgesupport
167+
build-iPhoneOS/
168+
build-iPhoneSimulator/
169+
170+
## Specific to RubyMotion (use of CocoaPods):
171+
#
172+
# We recommend against adding the Pods directory to your .gitignore. However
173+
# you should judge for yourself, the pros and cons are mentioned at:
174+
# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
175+
# vendor/Pods/
176+
177+
## Documentation cache and generated files:
178+
/.yardoc/
179+
/_yardoc/
180+
/doc/
181+
/rdoc/
182+
183+
## Environment normalization:
184+
/.bundle/
185+
/vendor/bundle
186+
/lib/bundler/man/
187+
188+
# for a library or gem, you might want to ignore these files since the code is
189+
# intended to run in multiple environments; otherwise, check them in:
190+
# Gemfile.lock
191+
# .ruby-version
192+
# .ruby-gemset
193+
194+
# unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
195+
.rvmrc
196+
197+
# Used by RuboCop. Remote config files pulled in from inherit_from directive.
198+
# .rubocop-https?--*
199+
200+
### Ruby Patch ###
201+
# Used by RuboCop. Remote config files pulled in from inherit_from directive.
202+
# .rubocop-https?--*
203+
204+
# End of https://www.toptal.com/developers/gitignore/api/ruby,python
205+
206+
.kitchen/
207+
.kitchen.local.yml

.pre-commit-config.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
repos:
3+
- repo: https://github.com/pre-commit/pre-commit-hooks
4+
rev: v2.3.0
5+
hooks:
6+
- id: check-added-large-files
7+
- id: check-executables-have-shebangs
8+
- id: pretty-format-json
9+
args:
10+
- --indent=2
11+
- --autofix
12+
- id: check-merge-conflict
13+
- id: check-symlinks
14+
- id: check-toml
15+
- id: check-vcs-permalinks
16+
# - repo: https://github.com/ansible/ansible-lint
17+
# rev: v4.2.0
18+
# hooks:
19+
# - id: ansible-lint
20+
- repo: https://github.com/adrienverge/yamllint
21+
rev: v1.19.0
22+
hooks:
23+
- id: yamllint
24+
args: [-s]
25+
- repo: https://gitlab.com/smop/pre-commit-hooks
26+
rev: v1.0.0
27+
hooks:
28+
- id: check-poetry

.tool-versions

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
python 3.9.0
2+
ruby 2.7.2

0 commit comments

Comments
 (0)