mirror of
https://github.com/vimagick/dockerfiles.git
synced 2025-02-09 13:47:10 +02:00
parent
17f8b8927a
commit
8277c9e8ba
@ -5,7 +5,7 @@
|
||||
FROM alpine
|
||||
MAINTAINER kev <noreply@easypi.pro>
|
||||
|
||||
WORKDIR /app
|
||||
WORKDIR /data
|
||||
|
||||
RUN set -xe \
|
||||
&& apk add --no-cache nodejs nodejs-npm \
|
||||
|
@ -10,15 +10,15 @@ Get a full fake REST API with zero coding in less than 30 seconds (seriously) wi
|
||||
```yaml
|
||||
json-server:
|
||||
image: vimagick/json-server
|
||||
command: -w db.json
|
||||
command: -H 0.0.0.0 -p 3000 -w db.json
|
||||
ports:
|
||||
- "3000:3000"
|
||||
volumes:
|
||||
- ./db.json:/app/db.json
|
||||
- ./data:/data
|
||||
restart: always
|
||||
```
|
||||
|
||||
## db.json
|
||||
## data/db.json
|
||||
|
||||
```json
|
||||
{
|
||||
|
@ -1,8 +1,8 @@
|
||||
json-server:
|
||||
image: vimagick/json-server
|
||||
command: -w db.json
|
||||
command: -H 0.0.0.0 -p 3000 -w db.json
|
||||
ports:
|
||||
- "3000:3000"
|
||||
volumes:
|
||||
- ./db.json:/app/db.json
|
||||
- ./data:/data
|
||||
restart: always
|
||||
|
Loading…
x
Reference in New Issue
Block a user