Skip to content

Commit

Permalink
Merge pull request #377 from Kegbot/mikey/v1.3-updates
Browse files Browse the repository at this point in the history
Remove cruft, update docs, get tests passing
  • Loading branch information
mik3y authored Feb 22, 2020
2 parents bd9201b + bbab0f0 commit 070c191
Show file tree
Hide file tree
Showing 72 changed files with 1,548 additions and 2,770 deletions.
5 changes: 5 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.git
build/
*.egg-info
docs/build/
dist/
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
*.egg-info
.coverage
.noseids
.vscode

### docs
docs/build
Expand Down
36 changes: 9 additions & 27 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,19 @@
language: python

python:
- "2.7"
sudo: false

notifications:
email: false

cache: pip

services:
- redis-server
- mysql
- redis

before_script:
- mysql -e 'create database kegbot_travis_test;'
before_install:
- mysql -e 'CREATE DATABASE kegbot;'
- mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root mysql
- mkdir -p ~/kegbot-data/media
- mkdir -p ~/kegbot-data/static
- mkdir -p ~/.kegbot/
- cp deploy/travis/local_settings.py ~/.kegbot/

install:
- pip install -r requirements.txt
- pip install .
install:
- pip install pipenv
- pipenv install --dev --deploy

script:
- kegbot test --traverse-namespace --first-package-wins

deploy:
provider: pypi
user: mikey
password:
secure: amERhNGbfgTb/1vlWJ8SpDSTUlmx8GlysllFlqIT6H/X2+XiLFRjmH+T6UXWcHurGzwC71/QC0LGlSg69d4wGarXKnDowInjA9NR+s763gcbWIKixAWxiVrHl/LHTd3n+5ZCaYVDjHCX4RCRdunQ3DESELCkJ4U9RCVHtIGki8k=
on:
tags: true
repo: Kegbot/kegbot-server
branch: master
- pipenv run pytest
37 changes: 37 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
FROM python:2.7-alpine

RUN mkdir /app
WORKDIR /app

ENV SHELL=/bin/sh \
PIP_NO_CACHE_DIR=1 \
KEGBOT_DATA_DIR=/kegbot-data \
KEGBOT_IN_DOCKER=True \
KEGBOT_ENV=debug

RUN apk update && \
apk add --no-cache \
bash \
curl \
libjpeg \
libjpeg-turbo \
openjpeg && \
pip install pipenv

ADD Pipfile Pipfile.lock ./
RUN apk add --no-cache mariadb-connector-c-dev && \
apk add --no-cache --virtual _build-deps \
build-base mariadb-dev libjpeg-turbo-dev zlib-dev && \
pipenv install --deploy && \
apk del _build-deps

ADD bin ./bin
ADD pykeg ./pykeg
ADD setup.py ./
RUN pipenv run python setup.py develop
RUN pipenv run kegbot collectstatic -v 0 --noinput

VOLUME ["/kegbot-data"]

EXPOSE 8000
CMD ["/usr/local/bin/pipenv", "run", "gunicorn", "pykeg.web.wsgi:application", "-b", "0.0.0.0:8000"]
78 changes: 78 additions & 0 deletions Pipfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]
kegbot = {editable = true,path = "."}

[packages]
amqp = "==2.1.4"
billiard = "==3.5.0.2"
celery = "==4.0.2"
certifi = "==2017.4.17"
chardet = "==3.0.4"
colorama = "==0.3.9"
coloredlogs = "==7.3.1"
configparser = "==3.5.0"
contextlib2 = "==0.5.5"
dj-database-url = "==0.4.2"
django-appconf = "==1.0.2"
django-bootstrap-pagination = "==1.6.2"
django-crispy-forms = "==1.6.1"
django-imagekit = "==4.0.1"
django-nose = "==1.4.4"
django-redis = "==4.8.0"
django-registration = "==2.2"
enum34 = "==1.1.6"
flake8 = "==3.3.0"
foursquare = "==1!2016.9.12"
funcsigs = "==1.0.2"
gunicorn = "==19.7.1"
httplib2 = "==0.10.3"
humanfriendly = "==4.4.1"
idna = "==2.5"
isodate = "==0.5.4"
jsonfield = "==2.0.2"
kegbot-api = "==1.1.0"
kegbot-pyutils = "==0.1.8"
kombu = "==4.0.2"
mccabe = "==0.6.1"
mock = "==2.0.0"
monotonic = "==1.4"
nose = "==1.3.7"
oauthlib = "==2.0.2"
olefile = "==0.44"
pbr = "==3.1.1"
pilkit = "==2.0"
protobuf = "==3.3.0"
pycodestyle = "==2.3.1"
pyflakes = "==1.5.0"
python-gflags = "==3.1.1"
pytz = "==2017.2"
redis = "==2.10.5"
rednose = "==1.2.2"
requests-mock = "==1.3.0"
requests-oauthlib = "==0.8.0"
requests = "==2.18.1"
six = "==1.10.0"
termstyle = "==0.1.11"
tweepy = "==3.5.0"
urllib3 = "==1.21.1"
vcrpy = "==1.11.1"
vine = "==1.1.3"
whitenoise = "==3.3.0"
wrapt = "==1.10.10"
Django = "==1.11.2"
Pillow = "==4.1.1"
PyYAML = "==3.12"
mysqlclient = "*"
sphinx = "*"
pytest = "*"
pytest-django = "*"

[scripts]
kegbot = "python bin/kegbot"

[requires]
python_version = "2.7"
Loading

0 comments on commit 070c191

Please sign in to comment.