-
Notifications
You must be signed in to change notification settings - Fork 147
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #270 from sbs20/staging
Proxy; Batch persistence; Locale names
- Loading branch information
Showing
25 changed files
with
225 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
## Reverse proxy | ||
|
||
scanservjs supports reverse proxying and uses relative paths throughout so no | ||
URL rewriting should be required. | ||
|
||
### Apache | ||
|
||
Example setup using a debian based distro. | ||
|
||
```sh | ||
sudo apt install apache2 | ||
sudo a2enmod proxy | ||
sudo a2enmod proxy_http | ||
sudo nano /etc/apache2/sites-available/000-default.conf | ||
``` | ||
|
||
Then add the following to a virtual host: | ||
|
||
``` | ||
<Location /scanner/> | ||
ProxyPass "http://127.0.0.1:8080/" | ||
ProxyPassReverse "http://127.0.0.1:8080/" | ||
</Location> | ||
``` | ||
|
||
And restart | ||
|
||
```sh | ||
sudo systemctl restart apache2 | ||
``` | ||
|
||
## nginx | ||
|
||
```sh | ||
sudo apt install nginx | ||
``` | ||
|
||
Edit your settings (e.g. `sudo nano /etc/nginx/sites-available/default`) | ||
|
||
And add the following inside your chosen server block | ||
|
||
``` | ||
# Increase timeouts since scan operations can take some time | ||
proxy_read_timeout 300; | ||
proxy_connect_timeout 300; | ||
proxy_send_timeout 300; | ||
location /scanner/ { | ||
proxy_set_header X-Real-IP $remote_addr; | ||
proxy_pass http://127.0.0.1:8080/; | ||
} | ||
``` | ||
|
||
Restart | ||
|
||
```sh | ||
sudo systemctl restart nginx | ||
``` |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.