Artix Linux Forum

General Category => Forum => Topic started by: Idlidev on 04 February 2022, 06:20:19

Title: [SOLVED] How to get rid of the 'artix' user when building a custom ISO?
Post by: Idlidev on 04 February 2022, 06:20:19
So about two days ago, I wanted to build a custom artix ISO. After building it, I found out that it auto creates a user called 'artix'. I wanted to completely remove this user. Is there a way to do so? I had searched a bit on the internet for a solution but couldn't find one. Any help would be highly appreciated!
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 04 February 2022, 17:15:46
Get /usr/bin/artix-live from artix-live-base and copy it in ~/artools-workspace/iso-profiles/custom-profile/live-overlay/usr/bin, or wherever is your custom profile stored. Edit configure_user() to your needs. Make sure to leave at least one active account (e.g. root), or you won't be able to login.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 08 February 2022, 16:23:16
@Idlidev, correction/addition: artix-live is used for setting up the live user in the ISO. The account's creation is handled by /usr/lib/sysusers.d/live-artix.conf (also part of artix-live-base), which you can create in the live-overlay directory and tweak.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 09 February 2022, 12:44:20
Hi nous!

I followed your instructions and was successful in removing the artix user.
The only concern that remains is that AUTOLOGIN=true isn't automatically logging in my custom user.
 
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 09 February 2022, 14:55:05
I bet your custom user isn't part of the autologin group. This is the job of /usr/bin/artix-live, IIRC the default is LIVEUSER=artix, near the bottom of the script.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 09 February 2022, 18:24:14
Hi nous,

I edited root-overlay/etc/group and added the liveuser to autologin group, I also edit artix-live and set it to my custom username.
Autologin still doesn't function.

This is the line I added:
autologin:x:967:liveuser
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 09 February 2022, 21:29:55
No, you don't have to (and mustn't) touch /etc/group in overlays. Only /usr/lib/sysusers.d/live-artix.conf and /usr/bin/artix-live to match.

After you boot, is you live user member of the autologin group?
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 10 February 2022, 01:48:08
I removed the group file in overlays, copied /usr/lib/sysusers.d/live-artix to root-overlay/usr/lib/sysusers.d/live-artix.conf.

Added the following line:
m liveuser autologin

my user did get added to autologin group , but still no sign of autologin.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 10 February 2022, 01:50:29
Code: [Select]
# artix live user
u liveuser 1000 - /home/liveuser /bin/zsh

m liveuser video
m liveuser power
m liveuser cdrom
m liveuser network
m liveuser lp
m liveuser scanner
m liveuser wheel
m liveuser log
m liveuser users
m liveuser autologin

This is the live-artix.conf file in the overlay.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 10 February 2022, 02:46:46
copied /usr/lib/sysusers.d/live-artix to root-overlay/usr/lib/sysusers.d/live-artix.conf.
Added the following line:
m liveuser autologin
my user did get added to autologin group , but still no sign of autologin.
This is the job of /usr/bin/artix-live, IIRC the default is LIVEUSER=artix, near the bottom of the script.
Is autologin group created? What's your login manager?
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 10 February 2022, 02:58:45
I did change LIVEUSER=artix in /usr/bin/artix-live.
The autologin group is created, yes. I am not using any display managers.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 10 February 2022, 03:11:16
This is the first thing you should have mentioned. You've wasted much of my time...
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 10 February 2022, 03:31:35
Oh..I'm extremely sorry. I assumed that setting up autologin with agetty is what AUTOLOGIN=true attempts.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 10 February 2022, 03:37:14
Copy your /etc/conf.d/agetty.tty1 to live-overlay and edit the agetty_options line to "-J -a liveuser". You can autologin thus in as many TTYs as you like.
Title: Re: How to get rid of the 'artix' user when building a custom ISO?
Post by: Shinyzenith on 10 February 2022, 03:40:30
Thank you so much nous, once again, very sorry for wasting your time.
Title: Re: [SOLVED] How to get rid of the 'artix' user when building a custom ISO?
Post by: nous on 10 February 2022, 04:06:03
It's worth mentioning that the agetty autologin doesn't need special group membership.