Correcting options for running curl only on IPv4.

This commit is contained in:
Emiliano Vavassori 2015-10-11 02:38:07 +02:00
parent dffa6108e1
commit 137db72cdf
6 changed files with 11 additions and 11 deletions

View File

@ -2,7 +2,7 @@
# Aggiorna crontab e logrotate forzosamente.
echo "$(date --rfc-3339=seconds) Loading and running init-ansible.sh"
/usr/bin/curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/init-ansible.sh | /bin/bash
/usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/init-ansible.sh | /bin/bash
# Script provvisorio.
# Potremmo decidere di far eseguire uno script generato da servizio
@ -15,7 +15,7 @@ branch=master
playbook=local.yml
echo "$(date --rfc-3339=seconds) Getting vault password"
vaultpassfile=$(/usr/bin/curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/getvaultpass.py | /usr/bin/python)
vaultpassfile=$(/usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/getvaultpass.py | /usr/bin/python)
echo "$(date --rfc-3339=seconds) Running ansible-pull"
/usr/bin/ansible-pull --accept-host-key -d "${repo}" -U "${url}" -C "${branch}" "${playbook}" --vault-password-file "${vaultpassfile}" $@

View File

@ -1 +1 @@
@reboot root /usr/bin/curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/ansible-pull.sh | /bin/bash >>/var/log/ansible-pull.log 2>&1
@reboot root /usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/ansible-pull.sh | /bin/bash >>/var/log/ansible-pull.log 2>&1

View File

@ -113,7 +113,7 @@ d-i preseed/late_command string in-target apt-get -y upgrade; \
in-target apt-get -y purge libnss-mdns unity-webapps-common zeitgeist-core zeitgeist-datahub epoptes; \
in-target apt-get -y autoremove; \
sed -i'' -e 's/ubuntu/gnome-fallback/g' /target/usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf; \
in-target /bin/bash -c "curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/preseed/postseed-client.sh | /bin/bash >/root/postseed.log 2>&1";
in-target /bin/bash -c "/usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/preseed/postseed-client.sh | /bin/bash >/root/postseed.log 2>&1";
# Grub installation on MBR
d-i grub-installer/only_debian boolean true

View File

@ -113,7 +113,7 @@ d-i preseed/late_command string in-target apt-get -y upgrade; \
in-target apt-get -y purge libnss-mdns unity-webapps-common zeitgeist-core zeitgeist-datahub epoptes-client; \
in-target apt-get -y autoremove; \
sed -i'' -e 's/ubuntu/gnome-fallback/g' /target/usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf; \
in-target bash -c "curl -sSL http://{{ ansible_local.domain.serverfqdn }}/ks/preseed/postseed-docenti.sh | /bin/bash >/root/post-ks.log 2>&1";
in-target bash -c "/usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/preseed/postseed-docenti.sh | /bin/bash >/root/postseed.log 2>&1";
# Grub installation on MBR
d-i grub-installer/only_debian boolean true

View File

@ -1,9 +1,9 @@
#!/bin/bash
# Cambio username con quello fornito da servizio
TARGETHOSTNAME=$(wget -qO- http://{{ ansible_local.domain.serverfqdn }}:3000/whatsmyhostname)
TARGETHOSTNAME=$(/usr/bin/wget -qO- http://{{ ansible_local.domain.serverfqdn }}:3000/whatsmyhostname)
echo $TARGETHOSTNAME > /etc/hostname
sed -i'' -e "s/kickseed/$TARGETHOSTNAME/g" /etc/hosts
/bin/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
/usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/init-ansible.sh | /bin/bash

View File

@ -1,9 +1,9 @@
#!/bin/bash
# Cambio username con quello fornito da servizio
TARGETHOSTNAME=$(wget -qO- http://{{ ansible_local.domain.serverfqdn }}:3000/whatsmyhostname?role=docenti)
TARGETHOSTNAME=$(/usr/bin/wget -qO- http://{{ ansible_local.domain.serverfqdn }}:3000/whatsmyhostname?role=docenti)
echo $TARGETHOSTNAME > /etc/hostname
sed -i'' -e "s/kickseed/$TARGETHOSTNAME/g" /etc/hosts
/bin/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
/usr/bin/curl -sSL4 http://{{ ansible_local.domain.serverfqdn }}/ks/ansible-pull/init-ansible.sh | /bin/bash