1
Fork 0

Setup nodejs in docker file

This commit is contained in:
Jake Howard 2018-07-22 21:30:19 +01:00
parent 9feafdb8a1
commit c04040489e
Signed by: jake
GPG Key ID: 57AFB45680EDD477
5 changed files with 34 additions and 2 deletions

1
.nvmrc Normal file
View File

@ -0,0 +1 @@
10.5.0

View File

@ -11,10 +11,21 @@ WORKDIR /app
COPY Pipfile Pipfile
COPY Pipfile.lock Pipfile.lock
COPY .nvmrc .nvmrc
COPY package.json package.json
COPY package-lock.json package-lock.json
RUN pipenv install --deploy --system
COPY . /app
RUN /opt/setup-pyenv-nvm.sh npm install
COPY manage.py /app/manage.py
COPY project/ /app/project/
COPY static/ /app/static/
COPY templates/ /app/templates/
RUN ./manage.py collectstatic --noinput
ENTRYPOINT ["/opt/setup-pyenv-nvm.sh"]
EXPOSE 8000

View File

@ -27,6 +27,9 @@ services:
ports:
- "8000:8000"
volumes:
- ".:/app"
- ./project/:/app/project/
- ./static/:/app/static/
- ./templates/:/app/templates/
depends_on:
- db

5
package-lock.json generated Normal file
View File

@ -0,0 +1,5 @@
{
"name": "website",
"version": "1.0.0",
"lockfileVersion": 1
}

12
package.json Normal file
View File

@ -0,0 +1,12 @@
{
"name": "website",
"version": "1.0.0",
"description": "",
"scripts": {},
"repository": {
"type": "git",
"url": "git+https://github.com/RealOrangeOne/website.git"
},
"author": "",
"dependencies": {}
}