You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+30
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,7 @@ The [Parse Server guide](https://docs.parseplatform.org/parse-server/guide/) is
23
23
---
24
24
25
25
-[Local Development](#local-development)
26
+
-[Docker Deployment](#docker-deployment)
26
27
-[Helpful Scripts](#helpful-scripts)
27
28
-[Remote Deployment](#remote-deployment)
28
29
-[Heroku](#heroku)
@@ -50,6 +51,35 @@ The [Parse Server guide](https://docs.parseplatform.org/parse-server/guide/) is
50
51
7. By default the API route will use `/parse` as a base. You can change this by setting the environment variable `PARSE_MOUNT`, for example in the CLI run run `export PARSE_MOUNT=/app` to set the path to `app`.
51
52
8. Your Parse Server is not running and is connected to your local database named `dev` in which the data is stored that you manage via Parse Server.
52
53
54
+
## Docker Deployment
55
+
56
+
You can also run Parse Server using Docker:
57
+
58
+
1. Create a `.env` file with your configuration variables. For example:
59
+
```
60
+
APP_ID=myAppId
61
+
MASTER_KEY=myMasterKey
62
+
DATABASE_URI=mongodb://localhost:27017/parse
63
+
PORT=1337
64
+
PARSE_MOUNT=/parse
65
+
```
66
+
67
+
2. Run Docker with the following command, mounting volumes as needed:
68
+
```
69
+
docker build -t parse-server .
70
+
docker run -p 1337:1337 --env-file .env \
71
+
-v $(pwd)/logs:/usr/src/parse/logs \
72
+
-v $(pwd)/cloud:/usr/src/parse/cloud \
73
+
parse-server
74
+
```
75
+
76
+
This allows you to:
77
+
- Use an environment file for configuration
78
+
- Mount the logs directory to persist logs outside the container
79
+
- Mount the cloud directory to access your Cloud Code files from the container
80
+
81
+
You can customize the mounted volumes based on your needs, such as mounting config files or other directories that require persistence or runtime modifications.
82
+
53
83
## Helpful Scripts
54
84
These scripts can help you to develop your app for Parse Server:
0 commit comments