Auto Publish new pages

liss-bot 2021-12-12 01:26:40 +00:00
parent 4768826a0f
commit 304ff31dbc
3 changed files with 793 additions and 719 deletions

@ -4,6 +4,13 @@
<!-- readme: sponsors -start -->
<table>
<tr>
<td align="center">
<a href="https://github.com/BOZG">
<img src="https://avatars.githubusercontent.com/u/6022344?u=a52f42b946a1e1156f7bb9d7f65e9e28bb2da89f&v=4" width="80;" alt="BOZG"/>
<br />
<sub><b>Stephen Rigney</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/vlad-timofeev">
<img src="https://avatars.githubusercontent.com/u/11474041?v=4" width="80;" alt="vlad-timofeev"/>
@ -11,13 +18,6 @@
<sub><b>Vlad Timofeev</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/DylanBeMe">
<img src="https://avatars.githubusercontent.com/u/41838333?v=4" width="80;" alt="DylanBeMe"/>
<br />
<sub><b>DylanH</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/matthewjdegarmo">
<img src="https://avatars.githubusercontent.com/u/46715299?u=65f979e86de9dce8a5fe04df9775d32c6cefd73a&v=4" width="80;" alt="matthewjdegarmo"/>
@ -75,6 +75,13 @@
</a>
</td></tr>
<tr>
<td align="center">
<a href="https://github.com/walkxcode">
<img src="https://avatars.githubusercontent.com/u/71191962?v=4" width="80;" alt="walkxcode"/>
<br />
<sub><b>Walkx</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/onedr0p">
<img src="https://avatars.githubusercontent.com/u/213795?v=4" width="80;" alt="onedr0p"/>
@ -89,6 +96,13 @@
<sub><b>Dan Gilbert</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/BOZG">
<img src="https://avatars.githubusercontent.com/u/6022344?v=4" width="80;" alt="BOZG"/>
<br />
<sub><b>Stephen Rigney</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/BeginCI">
<img src="https://avatars.githubusercontent.com/u/57495754?v=4" width="80;" alt="BeginCI"/>
@ -102,7 +116,8 @@
<br />
<sub><b>David</b></sub>
</a>
</td>
</td></tr>
<tr>
<td align="center">
<a href="https://github.com/deepsourcebot">
<img src="https://avatars.githubusercontent.com/u/60907429?v=4" width="80;" alt="deepsourcebot"/>
@ -116,8 +131,7 @@
<br />
<sub><b>FormatToday</b></sub>
</a>
</td></tr>
<tr>
</td>
<td align="center">
<a href="https://github.com/Compunctus">
<img src="https://avatars.githubusercontent.com/u/5058853?v=4" width="80;" alt="Compunctus"/>
@ -145,7 +159,8 @@
<br />
<sub><b>Shreya Roy</b></sub>
</a>
</td>
</td></tr>
<tr>
<td align="center">
<a href="https://github.com/jnach">
<img src="https://avatars.githubusercontent.com/u/33467747?v=4" width="80;" alt="jnach"/>

@ -346,6 +346,8 @@ Docker containers run with a subset of [Linux Kernal's Capabilities](https://man
With Docker run, you can use the `--cap-drop` flag to remove capabilities, you can also use `--cap-drop=all` and then define just the required permissions using the `--cap-add` option. For a list of available capabilities, see the [Privilege Capabilities Docs](https://docs.docker.com/engine/reference/run/#runtime-privilege-and-linux-capabilities).
Note that dropping privileges and capabilities on runtime is not fool-proof, and often any leftover privileges can be used to re-escalate, see [POS36-C](https://wiki.sei.cmu.edu/confluence/display/c/POS36-C.+Observe+correct+revocation+order+while+relinquishing+privileges).
Here's an example using docker-compose, removing privileges that are not required for Dashy to run:
```yaml
@ -617,6 +619,8 @@ Note, that if you choose not to use `server.js` to serve up the app, you will lo
Example Configs
- [NGINX](#nginx)
- [Apache](#apache)
- [Caddy](#caddy)
- [Firebase](#firebase-hosting)
- [cPanel](#cpanel)
### NGINX
@ -638,6 +642,9 @@ server {
}
}
```
To use HTML5 history mode (`appConfig.routingMode: history`), replace the inside of the location block with: `try_files $uri $uri/ /index.html;`.
Then upload the build contents of Dashy's dist directory to that location.
For example: `scp -r ./dist/* [username]@[server_ip]:/var/www/dashy/html`
@ -652,6 +659,15 @@ In your Apache config, `/etc/apche2/apache2.conf` add:
AllowOverride All
Require all granted
</Directory>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.html$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.html [L]
</IfModule>
```
Add a `.htaccess` file within `/var/www/html/dashy/.htaccess`, and add:
@ -664,6 +680,39 @@ RewriteRule ^ index.html [QSA,L]
Then restart Apache, with `sudo systemctl restart apache2`
### Caddy
Caddy v2
```
try_files {path} /
```
Caddy v1
```
rewrite {
regexp .*
to {path} /
}
```
### Firebase Hosting
Create a file names `firebase.json`, and populate it with something similar to:
```
{
"hosting": {
"public": "dist",
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
]
}
}
```
### cPanel
1. Login to your WHM
2. Open 'Feature Manager' on the left sidebar

@ -35,6 +35,16 @@ Header set X-Frame-Options: "ALLOW-FROM http://[dashy-location]/"
---
## 404 On Static Hosting
If you're seeing Dashy's 404 page on initial load/ refresh, and then the main app when you go back to Home, then this is likely caused by the Vue router, and if so can be fixed in one of two ways.
The first solution is to switch the routing mode, from HTML5 `history` mode to `hash` mode, by setting `appConfig.routingMode` to `hash`.
If this works, but you wish to continue using HTML5 history mode, then a bit of extra [server configuration](/docs/management.md#web-server-configuration) is required. This is explained in more detaail in the [Vue Docs](https://router.vuejs.org/guide/essentials/history-mode.html). Once completed, you can then use `routingMode: history` again, for neater URLs.
---
## Yarn Error
For more info, see [Issue #1](https://github.com/Lissy93/dashy/issues/1)