Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
kszkepzes-backend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
JetBrains YouTrack
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
KSZK
DevTeam
kszkepzes
old
kszkepzes-backend
Commits
38f2ad22
Commit
38f2ad22
authored
5 years ago
by
Rafael László
Browse files
Options
Downloads
Patches
Plain Diff
cleanup
parent
d40803ff
No related branches found
No related tags found
No related merge requests found
Pipeline
#3170
passed
5 years ago
Stage: Build
Stage: Test
Changes
4
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
.travis.yml
+0
-24
0 additions, 24 deletions
.travis.yml
Dockerfile
+17
-17
17 additions, 17 deletions
Dockerfile
Dockerfile.prod
+0
-27
0 additions, 27 deletions
Dockerfile.prod
README.md
+1
-5
1 addition, 5 deletions
README.md
with
18 additions
and
73 deletions
.travis.yml
deleted
100644 → 0
+
0
−
24
View file @
d40803ff
language
:
python
python
:
-
"
3.5"
-
"
3.5-dev"
# 3.5 development branch
-
"
3.6"
-
"
3.6-dev"
# 3.6 development branch
-
"
3.7"
-
"
3.7-dev"
# 3.7 development branch
# - "nightly"
services
:
-
postgresql
# command to install dependencies
install
:
-
pip install -r requirements/development.txt
before_script
:
-
psql -c 'create database travis_ci_test;' -U postgres
env
:
-
DATABASE_URL="postgresql://postgres:postgres@postgres:5432/travis_ci_test"
# command to run tests
script
:
-
flake8 --max-line-length=125 --exclude=src/kszkepzes,migrations
-
python src/manage.py migrate
-
python src/manage.py test
This diff is collapsed.
Click to expand it.
Dockerfile
+
17
−
17
View file @
38f2ad22
# pull official base image
FROM
python:3.8.1
# set work directory
WORKDIR
/usr/src/app
# set environment variables
ENV
PYTHONDONTWRITEBYTECODE 1
ENV
PYTHONUNBUFFERED 1
ENV
TZ Europe/Budapest
ENV
HOME /home/app
ENV
APP_HOME /home/app/kszkepzes-backend
RUN
groupadd app
&&
useradd
-g
app app
&&
\
mkdir
-p
/home/app
&&
mkdir
$APP_HOME
&&
\
mkdir
$APP_HOME
/staticfiles
&&
mkdir
$APP_HOME
/mediafiles
WORKDIR
$APP_HOME
# install dependencies
RUN
apt-get
-y
update
RUN
apt-get
install
-y
python python-pip python-dev python-django-extensions postgresql-client netcat
RUN
pip
install
--upgrade
pip
COPY
./requirements/production.txt /usr/src/app/requirements.txt
COPY
./requirements/production.txt requirements.txt
RUN
apt-get
-y
update
&&
apt-get
install
-y
python python-pip python-dev python-django-extensions postgresql-client netcat
RUN
pip
install
-r
requirements.txt
RUN
apt-get
-y
update
&&
apt-get
-y
autoremove
COPY
./src $APP_HOME
RUN
chown
-R
app:app
$APP_HOME
# copy entrypoint.sh
COPY
./src/entrypoint.sh /usr/src/app/entrypoint.sh
USER
app
# copy project
COPY
./src /usr/src/app/
EXPOSE
8000
# run entrypoint.sh
ENTRYPOINT
["/usr/src/app/entrypoint.sh"]
\ No newline at end of file
CMD
["gunicorn", "kszkepzes.wsgi:application", "--bind", "0.0.0.0:8000"]
This diff is collapsed.
Click to expand it.
Dockerfile.prod
deleted
100644 → 0
+
0
−
27
View file @
d40803ff
FROM python:3.8.1
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
ENV TZ Europe/Budapest
ENV HOME /home/app
ENV APP_HOME /home/app/kszkepzes-backend
RUN groupadd app && useradd -g app app && \
mkdir -p /home/app && mkdir $APP_HOME && \
mkdir $APP_HOME/staticfiles && mkdir $APP_HOME/mediafiles
WORKDIR $APP_HOME
COPY ./requirements/production.txt requirements.txt
RUN apt-get -y update && apt-get install -y python python-pip python-dev python-django-extensions postgresql-client netcat
RUN pip install -r requirements.txt
COPY ./src $APP_HOME
RUN chown -R app:app $APP_HOME
USER app
EXPOSE 8000
CMD ["gunicorn", "kszkepzes.wsgi:application", "--bind", "0.0.0.0:8000"]
This diff is collapsed.
Click to expand it.
README.md
+
1
−
5
View file @
38f2ad22
...
...
@@ -6,7 +6,7 @@
## Követelmények
1.
python3
.5
1.
python3
+
2.
pip
## Fejlesztés
...
...
@@ -30,7 +30,3 @@ Atirányítási cím: `http://127.0.0.1:3000/api/v1/complete/authsch`
## Formális Követelmények
1.
flake8-nak feleljen meg
2.
125 karakternél ne legyen hosszabb sor
> TODO: Böviteni a követelményeket
> TODO: Windows-os leírás
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment