guysoft / CustomPiOS

A Raspberry Pi and other ARM devices distribution builder
GNU General Public License v3.0
508 stars 146 forks source link

WIP: XZ Image Handling + Removed Pi User #164

Closed pablosproject closed 1 year ago

pablosproject commented 2 years ago

This fixes new changes in new Raspberry images. In detail:

@guysoft I also edited the wiki with the new default user module, let me know if you are happy with it.

guysoft commented 2 years ago

Hey, looks good! There is some indentation that needs fixing.

Should I start fixing it or would you like to continue to finalize it?

pablosproject commented 2 years ago

I am looking into the impact of the default-user. We already have BASE_USER and BASE_USER_ADD in the base module. It also does minor things using the BASE_USER variable (creates python configs, etc).

So in my tests, I ran the base module and the new default-user module, and everything worked, but I am not sure this is correct. I think that we can just remove the default-user module and use the default BASE_USER, forcing the default BASE_USER_ADD to true. This is because the base module needs a user set up to work correctly. What do you think?

guysoft commented 2 years ago

Ok, looking in to it more I think

  1. the base module should handle the default user
  2. the service userconf.service manages all the changes of user naming, perhaps we could just disable it.
guysoft commented 2 years ago

Hey, so I merged the XZ section of this PR. but not the last part that deals with the default user, that needs changing.

pablosproject commented 2 years ago

Ok, I am out of the office until tomorrow, then I will find a solution for the default user handling in the base module.

pablosproject commented 2 years ago

I tried reconciling both modules but had no luck, so here's what I'm doing:

I'll explain in the documentation of the base module this new change and we'll force that. In case someone wants to run the raspberry wizard to create the user, BASE_ADD_USER needs to be set to false, and some functions (like git clone) will not work during the build (but the user will know that as he prompted for not creating a new user).

Will finalize and test as soon as I can this change.

guysoft commented 2 years ago

Take a look at this branch: https://github.com/guysoft/CustomPiOS/tree/default-user

ill merge that once we fix the default user issue

pablosproject commented 2 years ago

Ok, looks good. The user creation is done on the first boot or when CustomPiOs build script runs? Because in the latter options some modules may not work correctly.

guysoft commented 2 years ago

In the former, it happens on first boot.

pablosproject commented 2 years ago

Ok, fine then.

guysoft commented 1 year ago

Hey, just wondering if there anything I can help with to get this merged?

pablosproject commented 1 year ago

Hi! Let me get my head around this because I forgot what I did. From what I recall just some part from this were merged:

The thing related to the default user was solved in another commit. Is that correct? I think here https://github.com/guysoft/CustomPiOS/commit/30c8b7f97b150dad5e13bf7f9197d2a707729f38

guysoft commented 1 year ago

Yes, this is what I see too. so I think this can be closed

pablosproject commented 1 year ago

Agree, thanks for checking