Compare commits

..

9 Commits

Author SHA1 Message Date
Reese
d2bf889e1f Update .gitlab-ci.yml 2020-04-25 02:32:29 +00:00
Reese
a70aa8840f Update Dockerfile 2020-04-25 02:32:06 +00:00
ducoterra
8404d43222 use venv for tests 2020-04-24 22:10:36 -04:00
ducoterra
f31106dd29 add venv 2020-04-24 22:06:56 -04:00
ducoterra
fbd8b0e2a7 python -m 2020-04-24 21:59:30 -04:00
Reese
b04ef5a579 Security fix: don’t run as root 2020-04-25 01:43:46 +00:00
ducoterra
e01bf28646 collectstatic 2020-04-24 21:26:21 -04:00
ducoterra
f362194c5e add README 2020-04-24 21:20:12 -04:00
ducoterra
bdc4c90705 wrong port for the service 2020-04-24 21:18:28 -04:00
4 changed files with 14 additions and 2 deletions

View File

@@ -8,4 +8,10 @@ COPY manage.py manage.py
COPY requirements.txt requirements.txt
RUN pip install -r requirements.txt
RUN useradd -ms /bin/bash django
RUN chown -R django .
USER django
RUN python manage.py collectstatic
CMD ["gunicorn","-b",":8000", "-w", "4", "config.wsgi"]

5
README.md Normal file
View File

@@ -0,0 +1,5 @@
# CI Builder
My CI testing pipeline for a django project.
[![pipeline status](http://gitlab.ducoterra.net/ducoterra/ci_builder/badges/master/pipeline.svg)](http://gitlab.ducoterra.net/ducoterra/ci_builder/-/commits/master)

View File

@@ -122,3 +122,4 @@ USE_TZ = True
# https://docs.djangoproject.com/en/3.0/howto/static-files/
STATIC_URL = '/static/'
STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles')

View File

@@ -33,7 +33,7 @@ spec:
kind: Rule
services:
- name: test
port: 80
port: 8000
---
@@ -49,6 +49,6 @@ spec:
kind: Rule
services:
- name: test
port: 80
port: 8000
middlewares:
- name: httpsredirect