1
0
mirror of https://github.com/kremalicious/portfolio.git synced 2024-12-22 17:23:22 +01:00
This commit is contained in:
Matthias Kretschmann 2018-09-20 00:34:48 +02:00
parent 708fe21e92
commit 4cc02d2e52
Signed by: m
GPG Key ID: 606EEEF3C479A91F
4 changed files with 13 additions and 8 deletions

View File

@ -1 +1,4 @@
node_modules node_modules
.git*
.cache
public

View File

@ -1,7 +1,5 @@
FROM node:alpine FROM node:alpine
EXPOSE 8000
RUN apk update && \ RUN apk update && \
apk add --update --repository http://dl-3.alpinelinux.org/alpine/edge/testing \ apk add --update --repository http://dl-3.alpinelinux.org/alpine/edge/testing \
vips-tools \ vips-tools \
@ -21,8 +19,9 @@ RUN apk update && \
RUN mkdir -p /portfolio RUN mkdir -p /portfolio
WORKDIR /portfolio WORKDIR /portfolio
VOLUME /portfolio
COPY ./scripts/entry.sh / COPY package.json .
RUN chmod +x /entry.sh
ENTRYPOINT ["/entry.sh"] RUN npm install --quiet && npm cache clean --force
#CMD [ "npm", "run", "dev" ]

View File

@ -2,7 +2,9 @@ version: '3'
services: services:
gatsby: gatsby:
build: . build: .
command: npm run dev
volumes: volumes:
- .:/portfolio - .:/portfolio
- /portfolio/node_modules
ports: ports:
- "8000:8000" - '8000:8000'

View File

@ -7,11 +7,12 @@
"license": "MIT", "license": "MIT",
"author": "Matthias Kretschmann <m@kretschmann.io>", "author": "Matthias Kretschmann <m@kretschmann.io>",
"scripts": { "scripts": {
"start": "npm run dev",
"lint:js": "eslint ./gatsby-*.js && eslint ./src/**/*.{js,jsx}", "lint:js": "eslint ./gatsby-*.js && eslint ./src/**/*.{js,jsx}",
"lint:css": "stylelint ./src/**/*.{css,scss}", "lint:css": "stylelint ./src/**/*.{css,scss}",
"lint": "npm run svg && npm run lint:js && npm run lint:css", "lint": "npm run svg && npm run lint:js && npm run lint:css",
"build": "npm run svg && ./node_modules/gatsby/dist/bin/gatsby.js build", "build": "npm run svg && ./node_modules/gatsby/dist/bin/gatsby.js build",
"start": "npm run svg && ./node_modules/gatsby/dist/bin/gatsby.js develop", "dev": "npm run svg && ./node_modules/gatsby/dist/bin/gatsby.js develop",
"format": "prettier --write 'src/**/*.{js,jsx}'", "format": "prettier --write 'src/**/*.{js,jsx}'",
"format:css": "prettier-stylelint --write --quiet 'src/**/*.{css,scss}'", "format:css": "prettier-stylelint --write --quiet 'src/**/*.{css,scss}'",
"test": "npm run lint && ./node_modules/.bin/ava **/*.test.js --verbose", "test": "npm run lint && ./node_modules/.bin/ava **/*.test.js --verbose",