Skip to content

Commit 5a6c3cc

Browse files
author
Patrick Koss
committed
add pipelines
1 parent e1a901d commit 5a6c3cc

File tree

10 files changed

+334
-0
lines changed

10 files changed

+334
-0
lines changed

.githooks/pre-push

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Semgrep
2+
3+
on:
4+
# Scan changed files in PRs, block on new issues only (existing issues ignored)
5+
pull_request: {}
6+
7+
jobs:
8+
semgrep:
9+
name: Scan
10+
runs-on: ubuntu-latest
11+
# Skip any PR created by dependabot to avoid permission issues
12+
if: (github.actor != 'dependabot[bot]')
13+
steps:
14+
# Fetch project source
15+
- uses: actions/checkout@v3
16+
17+
- uses: returntocorp/semgrep-action@v1
18+
with:
19+
config: >- # more at semgrep.dev/explore
20+
p/security-audit
21+
p/secrets
22+
p/ci
23+
p/r2c
24+
p/r2c-ci
25+
p/docker
26+
p/dockerfile
27+
p/command-injection
28+
generateSarif: "1"
29+
30+
# Upload findings to GitHub Advanced Security Dashboard [step 2/2]
31+
- name: Upload SARIF file for GitHub Advanced Security Dashboard
32+
uses: github/codeql-action/upload-sarif@29b1f65c5e92e24fe6b6647da1eaabe529cec70f # v2.3.3
33+
with:
34+
sarif_file: semgrep.sarif
35+
if: always()

.github/ISSUE_TEMPLATE/bug.yaml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Bug Report
2+
description: File a bug report
3+
labels: [ bug, triage ]
4+
assignees:
5+
- patrickkoss
6+
- Slm0n87
7+
- mgalm
8+
body:
9+
- type: markdown
10+
attributes:
11+
value: |
12+
Thanks for taking the time to fill out this bug report! Please fill the form below.
13+
- type: textarea
14+
id: what-happened
15+
attributes:
16+
label: What happened?
17+
description: Also tell us, what did you expect to happen?
18+
validations:
19+
required: true
20+
- type: textarea
21+
id: reproducible
22+
attributes:
23+
label: How can we reproduce this?
24+
description: Please share as much information as possible. Logs, screenshots, etc.
25+
validations:
26+
required: true
27+
- type: checkboxes
28+
id: search
29+
attributes:
30+
label: Search
31+
options:
32+
- label: I did search for other open and closed issues before opening this.
33+
required: true
34+
- type: checkboxes
35+
id: terms
36+
attributes:
37+
label: Code of Conduct
38+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/SchwarzIT/.github/blob/main/CODE_OF_CONDUCT.md)
39+
options:
40+
- label: I agree to follow this project's Code of Conduct
41+
required: true
42+
- type: textarea
43+
id: ctx
44+
attributes:
45+
label: Additional context
46+
description: Anything else you would like to add
47+
validations:
48+
required: false

.github/ISSUE_TEMPLATE/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blank_issues_enabled: true
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Feature Request
2+
description: Request a new feature and/or enhancement to an existing feature
3+
labels: [enhancement, triage]
4+
assignees:
5+
- patrickkoss
6+
- mgalm
7+
- Slm0n87
8+
body:
9+
- type: markdown
10+
attributes:
11+
value: |
12+
Thanks for taking the time to fill out this feature request! Please fill the form below.
13+
- type: textarea
14+
id: is-it-a-problem
15+
attributes:
16+
label: Is your feature request related to a problem? Please describe.
17+
description: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
18+
validations:
19+
required: true
20+
- type: textarea
21+
id: solution
22+
attributes:
23+
label: Describe the solution you'd like
24+
description: A clear and concise description of what you want to happen.
25+
validations:
26+
required: true
27+
- type: textarea
28+
id: alternatives
29+
attributes:
30+
label: Describe alternatives you've considered
31+
description: A clear and concise description of any alternative solutions or features you've considered.
32+
validations:
33+
required: true
34+
- type: checkboxes
35+
id: search
36+
attributes:
37+
label: Search
38+
options:
39+
- label: I did search for other open and closed issues before opening this.
40+
required: true
41+
- type: checkboxes
42+
id: terms
43+
attributes:
44+
label: Code of Conduct
45+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/SchwarzIT/.github/blob/main/CODE_OF_CONDUCT.md)
46+
options:
47+
- label: I agree to follow this project's Code of Conduct
48+
required: true
49+
- type: textarea
50+
id: ctx
51+
attributes:
52+
label: Additional context
53+
description: Anything else you would like to add
54+
validations:
55+
required: false

.github/renovate.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"extends": [
3+
"config:base",
4+
"group:allNonMajor",
5+
":semanticCommits",
6+
":semanticCommitTypeAll(chore)",
7+
":gitSignOff"
8+
],
9+
"dependencyDashboard": false,
10+
"packageRules": [
11+
{
12+
"matchManagers": ["pipenv", "poetry", "pip-compile", "pip_requirements", "setup-cfg"],
13+
"matchUpdateTypes": ["major", "minor", "patch", "pin", "digest"],
14+
"automerge": true
15+
}
16+
]
17+
}

.github/semantic.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# config options found here: https://github.com/Ezard/semantic-prs
2+
3+
# Always validate the PR title, and ignore the commits
4+
titleOnly: true
5+
6+
scopes:
7+
- plugin
8+
- ci
9+
- deps
10+
11+
types:
12+
- feat
13+
- fix
14+
- docs
15+
- refactor
16+
- test
17+
- chore
18+
- revert
19+
- chore
20+
- chore(deps)

.github/workflows/main.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: CI/CD Pipeline
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
test:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v2
18+
19+
- name: Set up Python
20+
uses: actions/setup-python@v2
21+
with:
22+
python-version: '3.x'
23+
24+
- name: Lint and Test
25+
run: |
26+
make lint
27+
make test

.github/workflows/release.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Publish Python distribution to PyPI
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
deploy:
9+
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Check out the repo
14+
uses: actions/checkout@v2
15+
16+
- name: Set up Python
17+
uses: actions/setup-python@v2
18+
with:
19+
python-version: '3.x'
20+
21+
- name: Set version from tag
22+
run: echo "PACKAGE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
23+
24+
- name: Install dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
pip install setuptools wheel twine
28+
29+
- name: Build and publish
30+
env:
31+
TWINE_USERNAME: __token__
32+
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
33+
run: |
34+
python setup.py sdist bdist_wheel
35+
twine upload dist/*

.github/workflows/semgrep.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Semgrep
2+
3+
on:
4+
# Scan changed files in PRs, block on new issues only (existing issues ignored)
5+
pull_request: {}
6+
7+
jobs:
8+
semgrep:
9+
name: Scan
10+
runs-on: ubuntu-latest
11+
# Skip any PR created by dependabot to avoid permission issues
12+
if: (github.actor != 'dependabot[bot]')
13+
steps:
14+
# Fetch project source
15+
- uses: actions/checkout@v4
16+
17+
- uses: returntocorp/semgrep-action@v1
18+
with:
19+
config: >- # more at semgrep.dev/explore
20+
p/security-audit
21+
p/secrets
22+
p/ci
23+
p/r2c
24+
p/r2c-ci
25+
p/docker
26+
p/dockerfile
27+
p/command-injection
28+
generateSarif: "1"
29+
30+
# Upload findings to GitHub Advanced Security Dashboard [step 2/2]
31+
- name: Upload SARIF file for GitHub Advanced Security Dashboard
32+
uses: github/codeql-action/upload-sarif@a09933a12a80f87b87005513f0abb1494c27a716 # v2.21.4
33+
with:
34+
sarif_file: semgrep.sarif
35+
if: always()

setup.cfg

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
[metadata]
2+
name = certbot-dns-stackit
3+
version = attr: PACKAGE_VERSION
4+
description = STACKIT DNS Authenticator plugin for Certbot
5+
long_description = file: README.md
6+
long_description_content_type = text/markdown
7+
url = https://github.com/stackitcloud/certbot-dns-stackit
8+
author = STACKIT DNS
9+
author_email = stackit-dns@mail.schwarz
10+
license = Apache License 2.0
11+
classifiers =
12+
Development Status :: 5 - Production/Stable
13+
Environment :: Plugins
14+
Intended Audience :: System Administrators
15+
License :: OSI Approved :: Apache Software License
16+
Operating System :: POSIX :: Linux
17+
Programming Language :: Python
18+
Programming Language :: Python :: 3
19+
Programming Language :: Python :: 3.4
20+
Programming Language :: Python :: 3.5
21+
Programming Language :: Python :: 3.6
22+
Programming Language :: Python :: 3.7
23+
Programming Language :: Python :: 3.8
24+
Programming Language :: Python :: 3.9
25+
Programming Language :: Python :: 3.10
26+
Programming Language :: Python :: 3.11
27+
Topic :: Internet :: WWW/HTTP
28+
Topic :: Security
29+
Topic :: System :: Installation/Setup
30+
Topic :: System :: Networking
31+
Topic :: System :: Systems Administration
32+
Topic :: Utilities
33+
python_requires = >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*
34+
35+
[options]
36+
packages = find:
37+
include_package_data = True
38+
install_requires =
39+
acme>=2.6.0
40+
certbot>=2.6.0
41+
setuptools
42+
requests
43+
mock
44+
requests-mock
45+
mypy
46+
mypy-extensions
47+
types-requests
48+
types-urllib3
49+
flake8
50+
pydocstyle
51+
black
52+
click==8.0.4
53+
coverage
54+
55+
[options.entry_points]
56+
certbot.plugins =
57+
dns-stackit = certbot_dns_stackit.stackit:Authenticator
58+
59+
[options.packages.find]
60+
exclude =
61+
tests*

0 commit comments

Comments
 (0)