Skip to content

Commit

Permalink
Remove all external dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
milesmcc committed Jun 28, 2020
1 parent 4a89397 commit bb0dc2e
Show file tree
Hide file tree
Showing 11 changed files with 3,151 additions and 153 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ __pycache__/
*.py[cod]
*$py.class

# JavaScript packages
node_modules/

# C extensions
*.so

Expand Down
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,21 @@ FROM python:3-alpine
# Getting things ready
WORKDIR /usr/src/shynet
COPY Pipfile.lock Pipfile ./
COPY package.json package-lock.json ../
# Django expects node_modules to be in its parent directory.

# Install dependencies & configure machine
ARG GF_UID="500"
ARG GF_GID="500"
RUN apk update && \
apk add gettext curl bash && \
# URL from https://github.com/shlinkio/shlink/issues/596 :)
apk add gettext curl bash npm && \
curl -m 180 "https://download.maxmind.com/app/geoip_download?edition_id=GeoLite2-ASN&license_key=kKG1ebhL3iWVd0iv&suffix=tar.gz" | tar -xvz -C /tmp && \
curl -m 180 "https://download.maxmind.com/app/geoip_download?edition_id=GeoLite2-City&license_key=kKG1ebhL3iWVd0iv&suffix=tar.gz" | tar -xvz -C /tmp && \
mv /tmp/GeoLite2*/*.mmdb /etc && \
apk del curl && \
apk add --no-cache postgresql-libs && \
apk add --no-cache --virtual .build-deps gcc musl-dev postgresql-dev && \
npm i -P --prefix .. && \
pip install pipenv && \
pipenv install --system --deploy && \
apk --purge del .build-deps && \
Expand Down
7 changes: 1 addition & 6 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]
black = "*"

[packages]
django = "*"
django-allauth = "*"
Expand All @@ -26,6 +23,4 @@ pycountry = "*"
ipaddress = "*"
html2text = "*"
django-health-check = "*"

[pipenv]
allow_prereleases = true
django-npm = "*"
155 changes: 33 additions & 122 deletions Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit bb0dc2e

Please sign in to comment.