summaryrefslogtreecommitdiff
path: root/README.md
blob: f54d28f1bd17fce3522a97ce67f61e2db9f721cc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# pepper-paintings

### Install everything

```
npm install
npm install -g webpack-cli
scp web@giraffe.life:pepper-paintings/.env .
```

Change `OK_PRODUCTION` to false in the `.env` before running the app.


### Run the CMS

```
node index
```

Using the `.env` above, the CMS will run on http://lvh.me:6555/

Be aware that the `db.json` file is committed as part of the repo.
If you edit your local database, try not to cause a merge conflict :)
You can always pull the database from the server:

```
curl http://pepper.giraffe.life/db.json > db.json
```


### Watch for changes

```
webpack
```

This will build the file `public/bundle.js`

To build for production, do `webpack -p`, which will build and minify the bundle. Please do this before pushing a new revision of the site.


### On the server

I use `pm2` to manage my node projects on the server:

```
pm2 list
pm2 info pepper
pm2 restart pepper
```