all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#40344: inconsistent 'guix package --list-generations' for root
@ 2020-03-31  8:54 Efraim Flashner
  2020-03-31 15:45 ` Leo Famulari
  0 siblings, 1 reply; 6+ messages in thread
From: Efraim Flashner @ 2020-03-31  8:54 UTC (permalink / raw)
  To: 40344

[-- Attachment #1: Type: text/plain, Size: 811 bytes --]

When I run 'sudo guix package --list-generations' on a foreign distro
I get a list of all the profiles for all the users, not just for root.
When I run 'sudo guix package --list-generations' on Guix System I get:
guix package: error: profile '/var/guix/profiles/per-user/root/guix-profile' does not exist

1: it probably shouldn't error if the default profile doesn't exist
2: I like the idea of root being able to, say, clean up all the profiles
over a certain age (ie.: guix package --delete-generations 6m). On the
other hand it is unexpected behavior since root is "just another user"

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#40344: inconsistent 'guix package --list-generations' for root
  2020-03-31  8:54 bug#40344: inconsistent 'guix package --list-generations' for root Efraim Flashner
@ 2020-03-31 15:45 ` Leo Famulari
  2020-03-31 17:48   ` Efraim Flashner
  0 siblings, 1 reply; 6+ messages in thread
From: Leo Famulari @ 2020-03-31 15:45 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: 40344

On Tue, Mar 31, 2020 at 11:54:36AM +0300, Efraim Flashner wrote:
> When I run 'sudo guix package --list-generations' on a foreign distro
> I get a list of all the profiles for all the users, not just for root.

It's complicated on foreign distros, since they vary in how they
configure sudo, and since Guix is really based on login environments.

I think it's correct that you'd see your own user's generations. Doing
`sudo foo` doesn't totally change your user from Guix's point of view,
just your privilege level. You'd need `sudo --login` to become root.

Try `env`, `sudo env`, `sudo --login env`...

It's definitely not expected to see all the users' generations, though
(I can't reproduce that).

Exactly how it works on the foreign distro will probably vary by distro
and setup, however. `sudo guix ...` doesn't work at all on my Debian; it
fails with "sudo: guix: command not found" and I have to use `sudo
--login`.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#40344: inconsistent 'guix package --list-generations' for root
  2020-03-31 15:45 ` Leo Famulari
@ 2020-03-31 17:48   ` Efraim Flashner
  2020-03-31 18:17     ` Leo Famulari
  0 siblings, 1 reply; 6+ messages in thread
From: Efraim Flashner @ 2020-03-31 17:48 UTC (permalink / raw)
  To: Leo Famulari; +Cc: 40344-done

[-- Attachment #1: Type: text/plain, Size: 494 bytes --]

Looks like I messsed up the bug report completely and mixed up
--list-profiles and --list-generations.

If anyone is curious, when run as root, 'guix package --list-profiles'
on Guix system and on a foreign distro, for me, return a list of all the
profiles of all the users.

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#40344: inconsistent 'guix package --list-generations' for root
  2020-03-31 17:48   ` Efraim Flashner
@ 2020-03-31 18:17     ` Leo Famulari
  2020-03-31 18:30       ` Efraim Flashner
  0 siblings, 1 reply; 6+ messages in thread
From: Leo Famulari @ 2020-03-31 18:17 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: 40344-done

[-- Attachment #1: Type: text/plain, Size: 585 bytes --]

On Tue, Mar 31, 2020 at 08:48:03PM +0300, Efraim Flashner wrote:
> Looks like I messsed up the bug report completely and mixed up
> --list-profiles and --list-generations.
> 
> If anyone is curious, when run as root, 'guix package --list-profiles'
> on Guix system and on a foreign distro, for me, return a list of all the
> profiles of all the users.

Can you share the exact command you run and the result of `env` with
that sudo invocation? For example, if you are doing `sudo guix package
--list-profiles`, the result of `sudo env`? Having sanitized it as
necessary...

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#40344: inconsistent 'guix package --list-generations' for root
  2020-03-31 18:17     ` Leo Famulari
@ 2020-03-31 18:30       ` Efraim Flashner
  2020-03-31 18:56         ` Leo Famulari
  0 siblings, 1 reply; 6+ messages in thread
From: Efraim Flashner @ 2020-03-31 18:30 UTC (permalink / raw)
  To: Leo Famulari; +Cc: 40344-done

[-- Attachment #1: Type: text/plain, Size: 2219 bytes --]

On Tue, Mar 31, 2020 at 02:17:26PM -0400, Leo Famulari wrote:
> On Tue, Mar 31, 2020 at 08:48:03PM +0300, Efraim Flashner wrote:
> > Looks like I messsed up the bug report completely and mixed up
> > --list-profiles and --list-generations.
> > 
> > If anyone is curious, when run as root, 'guix package --list-profiles'
> > on Guix system and on a foreign distro, for me, return a list of all the
> > profiles of all the users.
> 
> Can you share the exact command you run and the result of `env` with
> that sudo invocation? For example, if you are doing `sudo guix package
> --list-profiles`, the result of `sudo env`? Having sanitized it as
> necessary...

This time I ran it as root directly
On my kids' computer:
root@E2140 /home/efraim# guix package --list-profiles
/var/guix/profiles/per-user/efraim/current-guix
/var/guix/profiles/per-user/efraim/guix-profile
/var/guix/profiles/per-user/kids/current-guix
/var/guix/profiles/per-user/kids/guix-profileo

Guix on Debian, also directly as root:
debian-box:/home/efraimf# guix package --list-profiles | tail -n20
/var/guix/profiles/per-user/user1/current-guix
/var/guix/profiles/per-user/user1/guix-profile
/var/guix/profiles/per-user/user2/guix-profile
/var/guix/profiles/per-user/user3/current-guix
/var/guix/profiles/per-user/user3/guix-profile
/var/guix/profiles/per-user/user4/current-guix
/var/guix/profiles/per-user/user4/guix-profile
/var/guix/profiles/per-user/user5/current-guix
/var/guix/profiles/per-user/user5/guix-profile
/root/.config/guix/current
/root/.guix-profile
/var/guix/profiles/per-user/user6/current-guix
/var/guix/profiles/per-user/user6/guix-profile
/var/guix/profiles/per-user/user7/current-guix
/var/guix/profiles/per-user/user7/guix-profile
/var/guix/profiles/per-user/user8/current-guix
/var/guix/profiles/per-user/user8/guix-profile
/var/guix/profiles/per-user/user9/current-guix
/var/guix/profiles/per-user/user9/guix-profile
/var/guix/profiles/per-user/user10/guix-profile

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#40344: inconsistent 'guix package --list-generations' for root
  2020-03-31 18:30       ` Efraim Flashner
@ 2020-03-31 18:56         ` Leo Famulari
  0 siblings, 0 replies; 6+ messages in thread
From: Leo Famulari @ 2020-03-31 18:56 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: 40344-done

[-- Attachment #1: Type: text/plain, Size: 107 bytes --]

Sorry to add to the confusion. I didn't even realize there was a
`guix package --list-profiles` command...

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-03-31 18:57 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-03-31  8:54 bug#40344: inconsistent 'guix package --list-generations' for root Efraim Flashner
2020-03-31 15:45 ` Leo Famulari
2020-03-31 17:48   ` Efraim Flashner
2020-03-31 18:17     ` Leo Famulari
2020-03-31 18:30       ` Efraim Flashner
2020-03-31 18:56         ` Leo Famulari

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.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.