Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
exclude-labels:
- 'skip-changelog'
template: |
## Change Log

$CHANGES
61 changes: 61 additions & 0 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: build

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:

runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9]

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel coveralls
python -m pip install --upgrade -r requirements-dev.txt
- name: Lint with flake8
run: |
flake8 proxyprotocol test
- name: Type checking with mypy
run: |
mypy proxyprotocol test
- name: Test with pytest
run: |
py.test --cov=proxyprotocol
- name: Report test coverage to Coveralls
if: success()
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
coveralls --service=github

docs:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.9'
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
python -m pip install --upgrade -r requirements-dev.txt
python -m pip install --upgrade -r doc/requirements.txt
- name: Build the Sphinx documentation
run: |
make -C doc html
52 changes: 52 additions & 0 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: publish

on:
release:
types: [ published ]

jobs:
deploy:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.9'
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel twine
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
python setup.py sdist bdist_wheel
twine upload dist/*

docs:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.9'
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
python -m pip install --upgrade -r requirements-dev.txt
python -m pip install --upgrade -r doc/requirements.txt
- name: Build the Sphinx documentation
run: |
make -C doc html
- name: Deploy to GitHub Pages
if: success()
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ github.token }}
publish_dir: ./doc/build/html
15 changes: 15 additions & 0 deletions .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: draft

on:
push:
branches:
- master

jobs:
update_release_draft:

runs-on: ubuntu-latest
steps:
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ github.token }}
1 change: 0 additions & 1 deletion .lvimrc
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
let g:ale_fix_on_save = 1
let g:ale_fixers = {
\ 'python': ['autopep8'],
\}
36 changes: 0 additions & 36 deletions .travis.yml

This file was deleted.

8 changes: 5 additions & 3 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
FROM python:3.9-alpine

WORKDIR /src
COPY . .

RUN pip install -U pip wheel setuptools typing-extensions

ARG install_arg="proxy-protocol"
ARG install_source=""
RUN apk --update add --virtual build-dependencies python3-dev build-base \
&& pip install "${install_arg}${install_source}" \
&& pip install -r requirements-all.txt \
&& apk del build-dependencies

ENTRYPOINT ["proxyprotocol-server"]
CMD ["--help"]
5 changes: 0 additions & 5 deletions docker/hooks/build

This file was deleted.

1 change: 1 addition & 0 deletions requirements-all.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
-e '.'
3 changes: 3 additions & 0 deletions test/requirements.txt → requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@ autopep8
pytest
pytest-asyncio
pytest-cov
rope

-r requirements-all.txt
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[mypy]
strict = true
python_version = 3.8
python_version = 3.9

[tool:pytest]
norecursedirs = doc
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
license = f.read()

setup(name='proxy-protocol',
version='0.6.0',
version='0.6.1',
author='Ian Good',
author_email='ian@icgood.net',
description='PROXY protocol library with asyncio server implementation',
Expand Down