On 10/31/2014 03:37 AM, Serge Scevenels wrote:
Hi all,

can somebody help me with this latest problem I am having :)

Can it be resolved by using a custom PYTHONSTARTUP script ? If it is the
case, can i have some hint :)

You can simplify some of 3) b&c by using ssh config and public key connections:

http://nerderati.com/2011/03/17/simplify-your-life-with-an-ssh-config-file/

Here is a SO answer that may help with a startup file:

http://stackoverflow.com/questions/9977446/connecting-to-a-remote-ipython-instance


Thks

On Friday, 24 October 2014 20:17:25 UTC+2, Serge Scevenels wrote:

    Hi Carlos,

    thanks for the reply.

    I managed to connect to the remote kernel !! I did it this way, and
    then I'll ask you if it can be simpler :)

    1. on the VM, I start a kernel with port set using the following
    command line:
    ipython kernel --profile=spyder --ip 0.0.0.0 --control=11111
    --shell=22222 --iopub=55555 --hb=33333 --stdin=44444
    --ipython-dir=/home/vagrant/.ipython -f /vagrant/.ipython-kernel.json

    2. i configured on the VM the corresponding forwarded port

    3. in Spyder, I select connect to an existing kernel and I provide :
       a. the json file located on the shared folder
       b. I provide the <user>@<ip guest>:<port> to connect to the
    machine via SSH
       c. I provide the password

    This is working great. I have been able to automatise step 1 and 2
    easily, so that I don't need to repeat these steps everytime I turn
    on my VM. However, evertime I start spyder on the host machine, I'll
    need to re-do step 3. Is there a way to automatize it at spyder start ?

    Thks,
    Serge

    On Tuesday, 21 October 2014 04:21:50 UTC+2, Carlos Córdoba wrote:

        Hi Serge,

        Since Spyder 2.3.1 this is very easy, using ssh. You need to go
        to the menu

             Consoles > Connect to an existing kernel

        and introduce the information about your remote kernel (i.e. ip
        address, remote user name, etc).

        One important thing to consider is that you need to ssh first to
        your remote machine using a regular terminal (i.e. outside
        Spyder), to avoid a lock while waiting for the connection
        confirmation.

        If you have any further doubts, please feel free to post them
        here :-)


        Cheers,
        Carlos

        El 20/10/14 a las #4, Serge Scevenels escribió:
        Hi,

        I would like to know how can i connect Spyder to an ipython
        kernel active on a vagrant VMs.

        I'd like to know what kind of config I should introduce as
        connection info, ssh key, etc...

        Maybe it is not yet supported. If it is the case, please let
        me know :)

        Thks,
        Serge
        --
        You received this message because you are subscribed to the
        Google Groups "spyder" group.
        To unsubscribe from this group and stop receiving emails from
        it, send an email to spyderlib+...@googlegroups.com.
        To post to this group, send email to spyd...@googlegroups.com.
        Visit this group at http://groups.google.com/group/spyderlib
        <http://groups.google.com/group/spyderlib>.
        For more options, visit https://groups.google.com/d/optout
        <https://groups.google.com/d/optout>.

--
You received this message because you are subscribed to the Google
Groups "spyder" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to spyderlib+unsubscr...@googlegroups.com
<mailto:spyderlib+unsubscr...@googlegroups.com>.
To post to this group, send email to spyderlib@googlegroups.com
<mailto:spyderlib@googlegroups.com>.
Visit this group at http://groups.google.com/group/spyderlib.
For more options, visit https://groups.google.com/d/optout.


--
Adrian Klaver
adrian.kla...@aklaver.com

--
You received this message because you are subscribed to the Google Groups 
"spyder" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to spyderlib+unsubscr...@googlegroups.com.
To post to this group, send email to spyderlib@googlegroups.com.
Visit this group at http://groups.google.com/group/spyderlib.
For more options, visit https://groups.google.com/d/optout.

Reply via email to