Skip to content

Commit 34033a6

Browse files
author
Nicola Greco
committed
Updating documentation and simplifying the command-line example
1 parent 3bab784 commit 34033a6

1 file changed

Lines changed: 32 additions & 26 deletions

File tree

‎README.md‎

Lines changed: 32 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,18 @@
44
[![NPM Version](https://img.shields.io/npm/v/ldnode.svg?style=flat)](https://npm.im/ldnode)
55
[![Gitter chat](https://img.shields.io/badge/gitter-join%20chat%20%E2%86%92-brightgreen.svg?style=flat)](http://gitter.im/linkeddata/ldnode)
66

7-
Linked Data Platform server based on [rdflib.js](https://github.com/linkeddata/rdflib.js) and [node.js](https://nodejs.org/). This is all you need to run distributed linked data apps on top of the file system.
7+
Ldnode implements the [Linked Data Platform](http://www.w3.org/TR/ldp/) and [Solid](https://github.com/solid) in [NodeJS](https://nodejs.org/). This is all you need to run distributed Linked Data apps on top of the file system.
88

9-
You can run ldnode as a [command-line tool](https://github.com/linkeddata/ldnode/blob/master/README.md#command-line-tool) or as a [library](https://github.com/linkeddata/ldnode/blob/master/README.md#library) for your Nodejs/Express app.
9+
You can run ldnode as a [command-line tool](https://github.com/linkeddata/ldnode/blob/master/README.md#command-line-tool) or as a [library](https://github.com/linkeddata/ldnode/blob/master/README.md#library) for your [Express](https://expressjs.com) app.
1010

1111
## Features
1212

13-
- [x] HEAD, OPTIONS, GET, PUT, POST, PATCH, DELETE support
13+
- [x] Linked Data Platform compliant HEAD, OPTIONS, GET, PUT, POST, PATCH, DELETE
1414
- [x] Proxy for cross-site data access
15-
- [x] Access control using RDF ACLs
15+
- [x] Access control using [Web Access Control](http://www.w3.org/wiki/WebAccessControl)
1616
- [x] WebID+TLS Authentication
17-
- [x] Mount as express' router
18-
- [x] Command line tool
1917
- [x] Real-time live updates (using WebSockets)
18+
- [ ] Identity provider for WebID+TLS
2019

2120

2221
## Command line tool
@@ -29,30 +28,40 @@ The command line tool has the following options
2928
Usage: ldnode [options]
3029
3130
Options:
32-
-v, --verbose Print the logs to console
33-
--version Print current ldnode version
34-
-m, --mount Where to mount Linked Data Platform (default: '/')
35-
-r, --root Root location on the filesystem to serve resources
36-
-p, --port Port to use
37-
-c, --cache Set cache time (in seconds), 0 for no cache
38-
-K, --key Path to the ssl key
39-
-C, --cert Path to the ssl cert
40-
--webid Enable WebID+TLS authentication
41-
-s, --secret HTTP Session secret key (e.g. "your secret phrase")
42-
-P, --proxy Use a proxy on example.tld/proxyPath
43-
--no-live Disable live support through WebSockets
44-
-sA, --suffix-acl Suffix for acl files (default: '.acl')
45-
-sM, --suffix-meta Suffix for metadata files (default: '.meta')
46-
-sE, --suffix-sse Suffix for SSE files (default: '.events')
31+
-v, --verbose Print the logs to console
32+
--version Print current ldnode version
33+
-m, --mount Where to mount Linked Data Platform (default: '/')
34+
-r, --root Root location on the filesystem to serve resources
35+
-p, --port Port to use
36+
-K, --key Path to the ssl key
37+
-C, --cert Path to the ssl cert
38+
--webid Enable WebID+TLS authentication
39+
-s, --secret HTTP Session secret key (e.g. "your secret phrase")
40+
-fU, --force-user Force a WebID to always be logged in (usefull when offline)
41+
-P, --proxy Use a proxy on example.tld/proxyPath
42+
--no-live Disable live support through WebSockets
43+
-sA, --suffix-acl Suffix for acl files (default: '.acl')
44+
-sM, --suffix-meta Suffix for metadata files (default: '.meta')
45+
-sE, --suffix-sse Suffix for SSE files (default: '.events')
46+
--no-error-pages Disable custom error pages (use Node.js default pages instead)
47+
--error-pages Folder from which to look for custom error pages files (files must be named <error-code>.html -- eg. 500.html)
48+
--skin URI to a skin to load (default: https://linkeddata.github.io/warp/#/list/)
4749
4850
```
4951

52+
### Run your server
53+
To start your Linked Data Platform server:
5054

51-
For example, to start your own server using the current folder:
55+
```bash
56+
$ ldnode --port 80
57+
```
58+
59+
To start your Solid server:
5260

5361
```bash
5462
$ ldnode --webid --port 443 --cert /path/to/cert --key /path/to/key
5563
```
64+
**Note**: In order to support WebID+TLS authentication you will need `--webid` but also the flags `--cert` and `--key` to specify the keypair of your SSL certificate, since WebID+TLS will only work over `HTTPS`.
5665

5766
## Library
5867

@@ -109,7 +118,7 @@ ldp.listen(3000, function() {
109118

110119
##### Advanced
111120

112-
You can integrate ldnode in your existing express app, by mounting the ldnode app on a specific path using `lnode(opts)`.
121+
You can integrate ldnode in your existing [Express](https://expressjs.org) app, by mounting the ldnode app on a specific path using `lnode(opts)`.
113122

114123
```javascript
115124
var ldnode = require('ldnode')
@@ -176,9 +185,6 @@ npm run test-(acl|formats|params|patch)
176185
</tbody>
177186
</table>
178187

179-
180-
181-
182188
#### Do you want to contribute?
183189

184190
- [Join us in Gitter](https://gitter.im/linkeddata/chat) to help with development or to hang out with us :)

0 commit comments

Comments
 (0)