GNU bug report logs - #59797
30.0.50; [wishlist] Using namespaces in Tramp's kubernetes integration

Previous Next

Package: emacs;

Reported by: Michael Albinus <michael.albinus <at> gmx.de>

Date: Sat, 3 Dec 2022 09:21:01 UTC

Severity: wishlist

Found in version 30.0.50

Fixed in version 31.1

Done: Michael Albinus <michael.albinus <at> gmx.de>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eshel Yaron <me <at> eshelyaron.com>
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: Aaron Gonzales <aarongonzales1 <at> gmail.com>, 59797 <at> debbugs.gnu.org, Filipp Gunbin <fgunbin <at> fastmail.fm>, Warren Lynn <wrn.lynn <at> gmail.com>
Subject: bug#59797: 30.0.50; [wishlist] Using namespaces in Tramp's kubernetes integration
Date: Wed, 24 Jul 2024 19:30:29 +0200
Hi Michael,

Michael Albinus <michael.albinus <at> gmx.de> writes:

> I gave it a first try. It turns out, that "+" is a bad choice, because
> it doesn't belong to tramp-host-regexp. I would need to rewrite host
> name handling in Tramp just for that, which is not desirable.
>
> tramp-host-regexp is "[%._[:alnum:]-]+". So we could take either "%" or
> "_" as namespace delimiter. I've decided for "%"; a complete remote file
> name for kubernetes is now "/kubernetes:[CONTAINER.]POD[%NAMESPACE]:/path/to/file".

Makes sense.  Thank you for tackling it so promptly!

> It works OK acc to my basic tests. I have appended the patch; I would
> really appreciate if you could give it more testing in your production
> environment. Please sync first with the Emacs or Tramp git repo; this
> morning I've pushed other changes there.

From a quick test, this mostly works fine.  There's one issue (typo?) in
tramp-kubernetes--namespace that causes a regression when there's no
explicit namespace and tramp-kubernetes-namespace is nil, it returns an
empty string instead of nil.

> What's left is file name completion for namespaces. I'm undecided
> whether we need this in practice; let's see how it goes as-it-is.

It's not very crucial for me, FWIW.


Cheers,

Eshel




This bug report was last modified 302 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.