Correcting sed script to change hostname. Changing preseed to input the correct password.

This commit is contained in:
Emiliano Vavassori 2015-10-02 23:32:53 +02:00
parent f68510d227
commit f72e6671d0
4 changed files with 4 additions and 4 deletions

View File

@ -56,7 +56,7 @@ d-i clock-setup/ntp-server string {{ ansible_local.domain.ntpserver }}
# User creation
d-i passwd/user-fullname string BgLUG User
d-i passwd/username string bglug
d-i passwd/user-password-crypted string 74810f762fb7a0d8011131b2d8509619
d-i passwd/user-password-crypted string $1$33bB/LIt$MEHmvzVIgYRJs/5L4z34L/
# Partitioning
d-i partman-auto/init_automatically_partition select biggest_free

View File

@ -56,7 +56,7 @@ d-i clock-setup/ntp-server string {{ ansible_local.domain.ntpserver }}
# User creation
d-i passwd/user-fullname string BgLUG User
d-i passwd/username string bglug
d-i passwd/user-password-crypted string 74810f762fb7a0d8011131b2d8509619
d-i passwd/user-password-crypted string $1$33bB/LIt$MEHmvzVIgYRJs/5L4z34L/
# Partitioning
d-i partman-auto/init_automatically_partition select biggest_free

View File

@ -3,7 +3,7 @@
# Cambio username con quello fornito da servizio
TARGETHOSTNAME=$(wget -qO- http://{{ ansible_local.domain.serverfqdn }}:3000/whatsmyhostname)
echo $TARGETHOSTNAME > /etc/hostname
sed -i "s/kickseed/$TARGETHOSTNAME/g" /etc/hosts
sed -i '' -e "s/kickseed/$TARGETHOSTNAME/g" /etc/hosts
# Installo i file necessari per ansible.
curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/init-ansible.sh | bash

View File

@ -3,7 +3,7 @@
# Cambio username con quello fornito da servizio
TARGETHOSTNAME=$(wget -qO- http://{{ ansible_local.domain.serverfqdn }}:3000/whatsmyhostname?role=docenti)
echo $TARGETHOSTNAME > /etc/hostname
sed -i "s/kickseed/$TARGETHOSTNAME/g" /etc/hosts
sed -i '' -e "s/kickseed/$TARGETHOSTNAME/g" /etc/hosts
# Installo i file necessari per ansible.
curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/init-ansible.sh | bash