From: Harry Putnam <reader@newsguy.com>
To: help-gnu-emacs@gnu.org
Subject: Re: emacsclient over ssh
Date: Thu, 25 Jun 2009 06:38:37 -0500 [thread overview]
Message-ID: <87d48s4k76.fsf@newsguy.com> (raw)
In-Reply-To: 20090625072824.GA6456@tomas
tomas@tuxteam.de writes:
> On Wed, Jun 24, 2009 at 11:47:19PM -0500, Harry Putnam wrote:
>
> [...]
>
>> Well, like I mentioned in OP.. I want to be able to tap into a gnus
>> session running on the remote...You can't do that with tramp [...]
>
>> Various other aggravations too.
>
> Have you thought of tunneling the emacs client <--> server connection
> through SSH?
>
> Not tried yet, and I'm not sure whether there is'nt any better way --
> (gurus invited to chime-in ;-) but that is a rough sketch of how I would
> proceed:
>
> (1) Start Emacs server on your server machine, tell it to listen on TCP:
> emacs --daemon --eval '(setq server-use-tcp t)'
> (of course, typically you wouldn't use --eval in the command line,
> but rather put (setq ...) into some suitable startup file)
> Now the Emacs daemon is running and accepting connections via tcp.
> Maybe you can access it directly from your local network. If
> security is enough, you might skip step (3).
>
> (2) Transfer the file ~/.emacs.d/server/server to your client machine.
> It contains (among other things) a cookie which the client has to
> present to the server to appease the dogs at its entrance.
>
> (3) Among those "other things" there is a server address and port
> number. With some shell magic, create a shell command along the
> lines of
> ssh -Llocalhost:<localport>:localhost:<emacsport> <youruser@yourserver>
> where you choose <localport> and extract <emacsport> from the file
> in (2) above
> Note that this step is only strictly necessary if you don't want
> to have your Emacs server listening in your home net (you'll have
> to dissuade it from doing so by some other means, though).
>
> (4) Give your client in the client machine the server cookie from (2).
> If you have done (3) and if <localport> and <emacsport> differ,
> you might have to edit the cookie file:
> emacsclient --server-file <the cookie from (2), edited if necessary>
>
> Of course, if you are more fluent in elisp, you might substitute the
> shell magic above with sufficient elisp magic. It's just more magic.
>
> (5) Let us know whether that works ;-)
Ahhh no... I think I'll pass. A simple edit in /etc/sshd_config was
all I needed.
next prev parent reply other threads:[~2009-06-25 11:38 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.1165.1245793203.2239.help-gnu-emacs@gnu.org>
2009-06-23 22:09 ` emacsclient over ssh Richard Riley
2009-06-23 23:13 ` suvayu ali
[not found] ` <mailman.1178.1245818812.2239.help-gnu-emacs@gnu.org>
2009-06-24 10:40 ` Richard Riley
2009-06-24 7:49 ` Tim X
2009-06-24 8:32 ` Josef G. Bauer
2009-06-24 12:13 ` Anselm Helbig
2009-06-25 4:47 ` Harry Putnam
2009-06-25 7:28 ` tomas
2009-06-25 11:38 ` Harry Putnam [this message]
[not found] ` <mailman.1230.1245914729.2239.help-gnu-emacs@gnu.org>
2009-06-25 11:13 ` Richard Riley
2009-06-25 12:20 ` tomas
[not found] ` <mailman.1238.1245932253.2239.help-gnu-emacs@gnu.org>
2009-06-25 12:47 ` Richard Riley
2009-06-25 12:49 ` Richard Riley
2009-06-23 21:39 Harry Putnam
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87d48s4k76.fsf@newsguy.com \
--to=reader@newsguy.com \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.