Skip to content

Commit 8c6e5fd

Browse files
committed
chore(passport): upgrade requirements
1 parent fbc1d14 commit 8c6e5fd

6 files changed

Lines changed: 25 additions & 33 deletions

File tree

rootfs/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ FROM registry.drycc.cc/drycc/base:bullseye as build-app
33
ADD web /web
44
WORKDIR /web
55

6-
ENV NODE_VERSION="16.14.2"
6+
ENV NODE_VERSION="16.20.0"
77

88
RUN install-stack node $NODE_VERSION && . init-stack \
99
&& npm install --global yarn \
@@ -15,7 +15,7 @@ FROM registry.drycc.cc/drycc/base:bullseye
1515
ENV DRYCC_UID=1001 \
1616
DRYCC_GID=1001 \
1717
DRYCC_HOME_DIR=/workspace \
18-
PYTHON_VERSION="3.10.4"
18+
PYTHON_VERSION="3.10.11"
1919

2020
RUN groupadd drycc --gid ${DRYCC_GID} \
2121
&& useradd drycc -u ${DRYCC_UID} -g ${DRYCC_GID} -s /bin/bash -m -d ${DRYCC_HOME_DIR}

rootfs/Dockerfile.test

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ FROM registry.drycc.cc/drycc/base:bullseye
22

33
ENV DRYCC_HOME_DIR=/workspace \
44
PGDATA="/var/lib/postgresql/data" \
5-
PYTHON_VERSION="3.10.4" \
6-
POSTGRES_VERSION="14.2" \
7-
GOSU_VERSION="1.14"
5+
PYTHON_VERSION="3.10.11" \
6+
POSTGRES_VERSION="14.5" \
7+
GOSU_VERSION="1.16"
88

99
COPY requirements.txt ${DRYCC_HOME_DIR}/requirements.txt
1010
COPY dev_requirements.txt ${DRYCC_HOME_DIR}/dev_requirements.txt

rootfs/api/utils.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
Helper functions used by the Drycc Passport server.
33
"""
44
import logging
5-
import six
65
import datetime
76

87
from django.utils.encoding import force_bytes
@@ -37,10 +36,7 @@ def __decorator(request, *args, **kwargs):
3736

3837
class TokenGenerator(PasswordResetTokenGenerator):
3938
def _make_hash_value(self, user, timestamp):
40-
return (
41-
six.text_type(user.pk) + six.text_type(timestamp) +
42-
six.text_type(user.is_active)
43-
)
39+
return f"{user.pk}{timestamp}{user.is_active}"
4440

4541

4642
token_generator = TokenGenerator()

rootfs/dev_requirements.txt

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
11
# test module
22
# test
33
# Run "make test-unit" for the % of code exercised during tests
4-
coverage==5.3
4+
coverage==7.2.5
55

66
# Run "make test-style" to check python syntax and style
7-
flake8==3.8.3
7+
flake8==3.9.2
88

99
# code coverage report at https://codecov.io/github/drycc/passport
10-
codecov==2.1.9
10+
codecov==2.1.13
1111

1212
# mock out python-requests, mostly k8s
13-
requests-mock==1.8.0
14-
15-
# tail a log and pipe into tbgrep to find all tracebacks
16-
tbgrep==0.3.0
13+
requests-mock==1.10.0

rootfs/passport/gunicorn/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
faulthandler.enable()
66

77
bind = '0.0.0.0'
8-
workers = int(os.environ.get('GUNICORN_WORKERS', 4))
8+
workers = int(os.environ.get('GUNICORN_WORKERS', 2))
99
worker_class = "uvicorn.workers.UvicornWorker"
1010

1111
pythonpath = dirname(dirname(dirname(realpath(__file__))))

rootfs/requirements.txt

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,16 @@
11
# Drycc passport requirements
2-
django==4.1.2
3-
pytz==2022.2.1
4-
django-auth-ldap==3.0.0
5-
django-cors-headers==3.7.0
6-
djangorestframework==3.12.4
2+
django==4.2.1
3+
pytz==2023.3
4+
django-auth-ldap==4.3.0
5+
django-cors-headers==4.0.0
6+
djangorestframework==3.14.0
77
gunicorn==20.1.0
8-
uvicorn==0.18.2
9-
asgiref==3.5.2
10-
psycopg2-binary==2.9.1
11-
requests==2.26.0
12-
requests-toolbelt==0.9.1
13-
django_redis==5.0.0
14-
dj-database-url==0.5.0
15-
django-oauth-toolkit==1.5.0
16-
whitenoise==5.3.0
17-
8+
uvicorn==0.22.0
9+
asgiref==3.6.0
10+
psycopg[binary]==3.1.9
11+
requests==2.30.0
12+
requests-toolbelt==1.0.0
13+
django_redis==5.2.0
14+
dj-database-url==2.0.0
15+
django-oauth-toolkit==1.7.1
16+
whitenoise==6.4.0

0 commit comments

Comments
 (0)