P
P
PakHaDne2020-05-22 16:04:23
SSH
PakHaDne, 2020-05-22 16:04:23

Is it possible to combine WSL + ssh?

Hello connoisseurs.
There is a computer with win10pro
installed wsl and ubuntu 18.
I'm trying to make a script to forward through the ssh port of the server to connect the database.
It seems like something even happened, I made a script on Ubuntu:
#!/bin/bash
ssh -fNT -L 13336:127.0.0.1:3306 -J [email protected] [email protected]
exit

I'm trying to execute the command on windows:
wsl.exe - e "/place/where/script/./ssh.sh" And I

get:
/bin/bash: warning: shell level (1000) too high, resetting to 1

if you execute the script - the port appears

Who can suggest options?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
a31, 2020-06-02
@a31

You can try to use bash.exe bash.exe ~/test.bash, this option works fine for me, but through wsl it was not possible to run the script.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question