forked from coolaj86/walnut.js
		
	pages -> sites
This commit is contained in:
		
							parent
							
								
									4d54de7025
								
							
						
					
					
						commit
						242e39361f
					
				
							
								
								
									
										46
									
								
								README.md
									
									
									
									
									
								
							
							
						
						
									
										46
									
								
								README.md
									
									
									
									
									
								
							| @ -106,7 +106,6 @@ Currently being tested with Ubuntu, Raspbian, and Debian on Digital Ocean, Raspb | ||||
| ├── node_modules | ||||
| ├── packages | ||||
| │   ├── apis | ||||
| │   ├── pages | ||||
| │   └── services | ||||
| └── var | ||||
|     └── sites | ||||
| @ -211,16 +210,16 @@ Deleting those files will rese | ||||
| Accessing static apps | ||||
| --------------------- | ||||
| 
 | ||||
| Static apps are stored in `packages/pages` | ||||
| Static apps are stored in `var/sites` | ||||
| 
 | ||||
| ``` | ||||
| # App ID as files with a list of packages they should load | ||||
| # note that '#' is used in place of '/' because files and folders may not contain '/' in their names | ||||
| /srv/walnut/packages/sites/<domain.tld#path>          # https://domain.tld/path | ||||
| /srv/walnut/packages/sites/<domain.tld>               # https://domain.tld and https://domain.tld/foo match | ||||
| /srv/walnut/var/sites/<domain.tld#path>          # https://domain.tld/path | ||||
| /srv/walnut/var/sites/<domain.tld>               # https://domain.tld and https://domain.tld/foo match | ||||
| 
 | ||||
| # packages are directories with reverse dns name      # For the sake of debugging these packages can be accessed directly, without a site by | ||||
| /srv/walnut/packages/pages/<tld.domain.package>       # matches apps.<domain.tld>/<package-name> and <domain.tld>/apps/<package-name> | ||||
| /srv/walnut/var/sites/<tld.domain.package>       # matches apps.<domain.tld>/<package-name> and <domain.tld>/apps/<package-name> | ||||
| ``` | ||||
| 
 | ||||
| Accessing REST APIs | ||||
| @ -246,18 +245,6 @@ The packages: | ||||
| ``` | ||||
| /srv/walnut/packages/ | ||||
| ├── api | ||||
| ├── pages | ||||
| │   └── com.example.hello | ||||
| │       └── index.html | ||||
| │             ''' | ||||
| │             <html> | ||||
| │               <head><title>com.example.hello</title></head> | ||||
| │               <body> | ||||
| │                 <h1>com.example.hello</h1> | ||||
| │               </body> | ||||
| │             </html> | ||||
| │             ''' | ||||
| │ | ||||
| ├── rest | ||||
| │   └── com.example.hello | ||||
| │      ├── package.json | ||||
| @ -278,6 +265,19 @@ The packages: | ||||
| │           ''' | ||||
| │ | ||||
| └── services | ||||
| /srv/walnut/var/ | ||||
| ├── sites | ||||
|     └── demo@example.com | ||||
|         └── index.html | ||||
|               ''' | ||||
|               <html> | ||||
|                 <head><title>demo@example.com</title></head> | ||||
|                 <body> | ||||
|                   <h1>demo@example.com</h1> | ||||
|                 </body> | ||||
|               </html> | ||||
|               ''' | ||||
|   | ||||
| ``` | ||||
| 
 | ||||
| The permissions: | ||||
| @ -287,13 +287,13 @@ The permissions: | ||||
| ├── client-api-grants | ||||
| │   └── cloud.foobar.me | ||||
| │         ''' | ||||
| │         com.example.hello     # refers to /srv/walnut/packages/rest/com.example.hello | ||||
| │         hello@example.com     # refers to /srv/walnut/packages/rest/hello@example.com | ||||
| │         ''' | ||||
| │ | ||||
| └── sites | ||||
|     └── daplie.me | ||||
|           ''' | ||||
|           com.example.hello     # refers to /srv/walnut/packages/pages/com.example.hello | ||||
|           seed@example.com      # refers to /srv/walnut/var/sites/seed@example.com | ||||
|           ''' | ||||
| ``` | ||||
| 
 | ||||
| @ -303,11 +303,3 @@ API | ||||
| ``` | ||||
| req.apiUrlPrefix => https://api.example.com/api/tld.domain.pkg | ||||
| ``` | ||||
| 
 | ||||
| TODO | ||||
| ---- | ||||
| 
 | ||||
| * HTTPS Key Pinning | ||||
| * Heroku (pending completion of PostgreSQL support) | ||||
| * [GunDB](https://gundb.io) Support | ||||
| * OpenID support | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user