Hi On 02.09.21 11:16, Valérie GIVAUDAN wrote:
Thank you for your answer. Yes I thought I could do this and so it pops up this question: FAi looks really very usefull but is it necessary to add in 50-host-classes every host I want to install ? I mean is there a way to read a file (for instance) with the different hosts name I want to install and fire FAI (instead of editing 50-host-classes )?
no, 50-host-classes is just for grouping your hosts into additional classes.Depending on how you set the users, you could, for example, simply create "scripts/DEFAULT/10_create_users.sh" script which does the following
case "$HOSTNAME" in name1) USERNAME=user1;; name2) USERNAME=user2;; *) USERNAME='' esac if [[ -z "$USERNAME" ]] then adduser "$USERNAME" ..... fi(Obviously probably too short script, but I hope that will help getting started - does it?)
Cheers Carsten -- Dr. Carsten Aulbert, Max Planck Institute for Gravitational Physics, Callinstraße 38, 30167 Hannover, Germany, Phone +49 511 762 17185
smime.p7s
Description: S/MIME Cryptographic Signature