fix more problems in docs
This commit is contained in:
parent
c404d65eef
commit
68903cb0f3
@ -8,11 +8,11 @@ Add this to your `~/.bashrc` or `~/.zshrc`:
|
||||
|
||||
```bash
|
||||
http () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R 80:localhost:"$1" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R 80:localhost:"$1" ssh.neur0tx.site
|
||||
}
|
||||
|
||||
httpa () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R "$1":80:localhost:"$2" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R "$1":80:localhost:"$2" ssh.neur0tx.site
|
||||
}
|
||||
```
|
||||
|
||||
@ -26,22 +26,22 @@ Now you can forward your services like this:
|
||||
|
||||
* Forward service on port `:80` with random subdomain:
|
||||
```sh
|
||||
$ ssh -p 2222 -R 80:localhost:80 ssh -p ssh.neur0tx.site
|
||||
$ ssh -p 2222 -R 80:localhost:80 ssh.neur0tx.site
|
||||
```
|
||||
* Forward service on port `:8080` with custom subdomain:
|
||||
```sh
|
||||
$ ssh -p 2222 -R subdomain:80:localhost:80 ssh -p ssh.neur0tx.site
|
||||
$ ssh -p 2222 -R subdomain:80:localhost:80 ssh.neur0tx.site
|
||||
```
|
||||
* For Fedora you can add `-oHostKeyAlgorithms=+ssh -p 2222-rsa` before `ssh -p 2222` to prevent any problems with the key compatibility.
|
||||
* For Fedora you can add `-oHostKeyAlgorithms=+ssh-rsa` before `ssh -p 2222` to prevent any problems with the key compatibility.
|
||||
* Function for `bash` / `zsh` to use as an alias (usage: `http 80`):
|
||||
```bash
|
||||
http () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R 80:localhost:"$1" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R 80:localhost:"$1" ssh.neur0tx.site
|
||||
}
|
||||
```
|
||||
* Same function but with custom subdomain (usage: `httpa subdomain 80`):
|
||||
```bash
|
||||
httpa () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R "$1":80:localhost:"$2" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R "$1":80:localhost:"$2" ssh.neur0tx.site
|
||||
}
|
||||
```
|
||||
|
@ -8,11 +8,11 @@
|
||||
|
||||
```bash
|
||||
http () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R 80:localhost:"$1" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R 80:localhost:"$1" ssh.neur0tx.site
|
||||
}
|
||||
|
||||
httpa () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R "$1":80:localhost:"$2" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R "$1":80:localhost:"$2" ssh.neur0tx.site
|
||||
}
|
||||
```
|
||||
|
||||
@ -26,22 +26,22 @@ httpa () {
|
||||
|
||||
* Проксировать сервис на порту `:80` на случайный поддомен:
|
||||
```sh
|
||||
$ ssh -p 2222 -R 80:localhost:80 ssh -p ssh.neur0tx.site
|
||||
$ ssh -p 2222 -R 80:localhost:80 ssh.neur0tx.site
|
||||
```
|
||||
* Проксировать сервис на порту `:8080` на заранее определенный поддомен:
|
||||
```sh
|
||||
$ ssh -p 2222 -R subdomain:80:localhost:80 ssh -p ssh.neur0tx.site
|
||||
$ ssh -p 2222 -R subdomain:80:localhost:80 ssh.neur0tx.site
|
||||
```
|
||||
* Для Fedora можно использовать аргумент `-oHostKeyAlgorithms=+ssh -p 2222-rsa` перед `ssh -p 2222` чтобы предотвратить проблемы совместимости с ключом.
|
||||
* Для Fedora можно использовать аргумент `-oHostKeyAlgorithms=+ssh-rsa` перед `ssh -p 2222` чтобы предотвратить проблемы совместимости с ключом.
|
||||
* Функции для `bash` / `zsh` чтобы использовать как alias (пример: `http 80`):
|
||||
```bash
|
||||
http () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R 80:localhost:"$1" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R 80:localhost:"$1" ssh.neur0tx.site
|
||||
}
|
||||
```
|
||||
* Та же функция с кастомным поддоменом (пример: `httpa subdomain 80`):
|
||||
```bash
|
||||
httpa () {
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh -p 2222-rsa -R "$1":80:localhost:"$2" ssh -p ssh.neur0tx.site
|
||||
ssh -p 2222 -oHostKeyAlgorithms=+ssh-rsa -R "$1":80:localhost:"$2" ssh.neur0tx.site
|
||||
}
|
||||
```
|
||||
|
Reference in New Issue
Block a user