Skip to content

Commit f15efac

Browse files
author
jesperorb
committedOct 30, 2020
Update readme and deps
1 parent a5b25a0 commit f15efac

File tree

4 files changed

+1289
-35
lines changed

4 files changed

+1289
-35
lines changed
 

‎.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules

‎README.md

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,8 @@
22

33
> Instructions how to deploy the full fake REST API [json-server](https://github.com/typicode/json-server) to various free hosting sites. Should only be used in development purpose but can act as a simpler database for smaller applications.
44
5-
<img src="https://raw.githubusercontent.com/typicode/json-server/master/src/server/public/images/json.png" align="right">
6-
75
* [**Create your database**](#create-your-database)
86
* [Deploy to **Heroku**](#deploy-to-heroku)
9-
* [Deploy to **now**](#deploy-to-now)
107
* [Deploy to **Azure**](#deploy-to-azure)
118

129

@@ -102,33 +99,6 @@ You also have to make changes to the port, you can't hardcode a dev-port. But yo
10299
const port = process.env.PORT || 4000;
103100
```
104101

105-
---
106-
107-
## Deploy to **now**
108-
109-
1 . [Create your database](#create-your-database)
110-
111-
2 . Install now cli-tool globally
112-
```bash
113-
npm install -g now
114-
```
115-
116-
3 . Run the `now` command in this folder/repo where your project is. If you run it for the first time, you will be prompted to login, after login, run the command again:
117-
```
118-
now --public
119-
```
120-
_`--public` is to skip the prompt telling you that you will open source your project if you deploy it to now_
121-
122-
4 . The URL will be copied automatically and you can just paste it into your browser.
123-
124-
5. **Optional**: Rename the deployment:
125-
```bash
126-
now alias https://your-deployed-name.now.sh new-name
127-
```
128-
_first argument is the deployed site, second argument is the new name to give it_
129-
130-
---
131-
132102
## Deploy to **Azure**
133103

134104
<img align="right" width="100px" height="auto" src="https://docs.microsoft.com/en-us/azure/media/index/azure-germany.svg" alt="Azure">

‎package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
{
2-
"name": "json-server-heroku",
2+
"name": "json-server-deploy",
33
"version": "1.0.0",
4-
"description": "Simple json-base database to deploy to Heroku",
4+
"description": "Simple json database to deploy to the host of your choice",
55
"main": "server.js",
66
"scripts": {
7-
"start": "node server.js",
8-
"dev": "nodemon server.js"
7+
"start": "node server.js"
98
},
109
"keywords": [
1110
"json-server,heroku, node, REST API"
1211
],
1312
"author": "Jesper Orb",
1413
"license": "ISC",
1514
"dependencies": {
16-
"json-server": "^0.12.1"
15+
"json-server": "^0.16.2"
1716
}
1817
}

‎yarn.lock

Lines changed: 1284 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)
Please sign in to comment.