puppet apply: add --summarize
... so we can know how long take resources configuration in Puppet catalogs, and more easily debug why we have timeouts. Change-Id: If3fae8837140caae91120e46b4880146ffe22afc
This commit is contained in:
parent
d05b39d149
commit
eb324768d0
@ -16,6 +16,7 @@
|
|||||||
puppet apply {{ host_puppet_config_debug|default('') }}
|
puppet apply {{ host_puppet_config_debug|default('') }}
|
||||||
--modulepath=/etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules
|
--modulepath=/etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules
|
||||||
--detailed-exitcodes
|
--detailed-exitcodes
|
||||||
|
--summarize
|
||||||
--logdest syslog --logdest console --color=false
|
--logdest syslog --logdest console --color=false
|
||||||
/var/lib/tripleo-config/puppet_step_config.pp
|
/var/lib/tripleo-config/puppet_step_config.pp
|
||||||
changed_when: outputs.rc == 2
|
changed_when: outputs.rc == 2
|
||||||
|
@ -225,7 +225,7 @@ def mp_puppet_config((config_volume, puppet_tags, manifest, config_image, volume
|
|||||||
sync
|
sync
|
||||||
|
|
||||||
set +e
|
set +e
|
||||||
FACTER_hostname=$HOSTNAME FACTER_uuid=docker /usr/bin/puppet apply \
|
FACTER_hostname=$HOSTNAME FACTER_uuid=docker /usr/bin/puppet apply --summarize \
|
||||||
--detailed-exitcodes --color=false --logdest syslog --logdest console --modulepath=/etc/puppet/modules:/usr/share/openstack-puppet/modules $TAGS /etc/config.pp
|
--detailed-exitcodes --color=false --logdest syslog --logdest console --modulepath=/etc/puppet/modules:/usr/share/openstack-puppet/modules $TAGS /etc/config.pp
|
||||||
rc=$?
|
rc=$?
|
||||||
set -e
|
set -e
|
||||||
|
@ -194,7 +194,7 @@ outputs:
|
|||||||
list_join:
|
list_join:
|
||||||
- '; '
|
- '; '
|
||||||
- - "cp -a /tmp/puppet-etc/* /etc/puppet; echo '{\"step\": 1}' > /etc/puppet/hieradata/docker.json"
|
- - "cp -a /tmp/puppet-etc/* /etc/puppet; echo '{\"step\": 1}' > /etc/puppet/hieradata/docker.json"
|
||||||
- "FACTER_uuid=docker puppet apply DEBUG --color=false --modulepath=/etc/puppet/modules:/usr/share/openstack-puppet/modules --tags TAGS -v -e 'CONFIG'"
|
- "FACTER_uuid=docker puppet apply DEBUG --color=false --summarize --modulepath=/etc/puppet/modules:/usr/share/openstack-puppet/modules --tags TAGS -v -e 'CONFIG'"
|
||||||
params:
|
params:
|
||||||
TAGS: 'tripleo::firewall::rule'
|
TAGS: 'tripleo::firewall::rule'
|
||||||
CONFIG:
|
CONFIG:
|
||||||
|
@ -271,7 +271,7 @@ resources:
|
|||||||
systemctl restart openvswitch
|
systemctl restart openvswitch
|
||||||
|
|
||||||
# DO NOT use --detailed-exitcodes
|
# DO NOT use --detailed-exitcodes
|
||||||
puppet apply --logdest console \
|
puppet apply --logdest console --summarize \
|
||||||
--modulepath /etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules \
|
--modulepath /etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules \
|
||||||
-e '
|
-e '
|
||||||
class {"vswitch::dpdk":
|
class {"vswitch::dpdk":
|
||||||
|
@ -12,6 +12,7 @@ function run_puppet {
|
|||||||
set +e
|
set +e
|
||||||
puppet apply --detailed-exitcodes \
|
puppet apply --detailed-exitcodes \
|
||||||
--modulepath \
|
--modulepath \
|
||||||
|
--summarize \
|
||||||
/etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules \
|
/etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules \
|
||||||
"${manifest}"
|
"${manifest}"
|
||||||
rc=$?
|
rc=$?
|
||||||
|
@ -235,7 +235,7 @@ outputs:
|
|||||||
- name: Run puppet apply to set tranport_url in nova.conf
|
- name: Run puppet apply to set tranport_url in nova.conf
|
||||||
tags: step5
|
tags: step5
|
||||||
when: is_bootstrap_node
|
when: is_bootstrap_node
|
||||||
command: puppet apply --modulepath /etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules --detailed-exitcodes /root/nova-api_upgrade_manifest.pp
|
command: puppet apply --summarize --modulepath /etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules --detailed-exitcodes /root/nova-api_upgrade_manifest.pp
|
||||||
register: puppet_apply_nova_api_upgrade
|
register: puppet_apply_nova_api_upgrade
|
||||||
failed_when: puppet_apply_nova_api_upgrade.rc not in [0,2]
|
failed_when: puppet_apply_nova_api_upgrade.rc not in [0,2]
|
||||||
changed_when: puppet_apply_nova_api_upgrade.rc == 2
|
changed_when: puppet_apply_nova_api_upgrade.rc == 2
|
||||||
|
Loading…
Reference in New Issue
Block a user