From: Martyn Taylor mtaylor@redhat.com
--- bin/aeolus-configure | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/bin/aeolus-configure b/bin/aeolus-configure index b4c1f39..310b76e 100644 --- a/bin/aeolus-configure +++ b/bin/aeolus-configure @@ -13,7 +13,14 @@ OPTIONS: EOF }
-eval set -- `getopt -o hdv --long help,debug,verbose -- "$@"` +args=`getopt -o :hdv --long help,debug,verbose -- "$@"` +if test $? != 0 + then + usage + exit 1 +fi + +eval set -- $args while true ; do case "$1" in -h|--help) usage ; exit 1 ; shift ;;
From: Martyn Taylor mtaylor@redhat.com
--- bin/aeolus-cleanup | 35 +++++++++++++++++++++++++++++++++-- 1 files changed, 33 insertions(+), 2 deletions(-)
diff --git a/bin/aeolus-cleanup b/bin/aeolus-cleanup index a2ff45f..22387a1 100644 --- a/bin/aeolus-cleanup +++ b/bin/aeolus-cleanup @@ -1,4 +1,35 @@ #!/bin/sh +usage() +{ +cat << EOF + +USAGE: +aeolus-cleanup [-d|--debug] [-h|--help] [-v|--verbose] + +OPTIONS: + -h | --help Show this message. + -d | --debug Debug logging mode. + -v | --verbose Verbose logging mode. +EOF +} + +args=`getopt -o :hdv --long help,debug,verbose -- "$@"` +if test $? != 0 + then + usage + exit 1 +fi + +eval set -- $args +while true ; do + case "$1" in + -h|--help) usage ; exit 1 ; shift ;; + -d|--debug) LOGLEVEL="--debug" ; shift ;; + -v|--verbose) LOGLEVEL="--verbose" ; shift ;; + --) shift ; break ;; + *) usage ; exit 1 ;; + esac +done
export FACTER_AEOLUS_ENABLE_HTTPS=true export FACTER_AEOLUS_ENABLE_SECURITY=false @@ -6,5 +37,5 @@ puppet /usr/share/aeolus-configure/modules/aeolus/manifests/defaults.pp \ --modulepath=/usr/share/aeolus-configure/modules/ \ --external_nodes '/usr/sbin/aeolus-node cleanup' --node_terminus exec \ --logdest=/var/log/aeolus-configure/aeolus-configure.log \ - --logdest=console - + --logdest=console \ + $LOGLEVEL
Ack'd. Work perfectly now. A+ to you martyn :)
Cheers, Francesco
On Thu, Jun 02, 2011 at 04:05:40PM +0100, mtaylor@redhat.com wrote:
From: Martyn Taylor mtaylor@redhat.com
bin/aeolus-cleanup | 35 +++++++++++++++++++++++++++++++++-- 1 files changed, 33 insertions(+), 2 deletions(-)
diff --git a/bin/aeolus-cleanup b/bin/aeolus-cleanup index a2ff45f..22387a1 100644 --- a/bin/aeolus-cleanup +++ b/bin/aeolus-cleanup @@ -1,4 +1,35 @@ #!/bin/sh +usage() +{ +cat << EOF
+USAGE: +aeolus-cleanup [-d|--debug] [-h|--help] [-v|--verbose]
+OPTIONS:
- -h | --help Show this message.
- -d | --debug Debug logging mode.
- -v | --verbose Verbose logging mode.
+EOF +}
+args=`getopt -o :hdv --long help,debug,verbose -- "$@"` +if test $? != 0
then
usage
exit 1
+fi
+eval set -- $args +while true ; do
case "$1" in
-h|--help) usage ; exit 1 ; shift ;;
-d|--debug) LOGLEVEL="--debug" ; shift ;;
-v|--verbose) LOGLEVEL="--verbose" ; shift ;;
--) shift ; break ;;
*) usage ; exit 1 ;;
esac
+done
export FACTER_AEOLUS_ENABLE_HTTPS=true export FACTER_AEOLUS_ENABLE_SECURITY=false @@ -6,5 +37,5 @@ puppet /usr/share/aeolus-configure/modules/aeolus/manifests/defaults.pp \ --modulepath=/usr/share/aeolus-configure/modules/ \ --external_nodes '/usr/sbin/aeolus-node cleanup' --node_terminus exec \ --logdest=/var/log/aeolus-configure/aeolus-configure.log \
--logdest=console
--logdest=console \
$LOGLEVEL
-- 1.7.4
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
On Thu, Jun 02, 2011 at 05:17:29PM +0200, Francesco Vollero wrote:
Ack'd. Work perfectly now. A+ to you martyn :)
Martyn sorry but Justin Clift pointed me to a curious thing, is normal that even the cleanup gonna log on aeolus-configure?
Cheers, Francesco
On Thu, Jun 02, 2011 at 04:05:40PM +0100, mtaylor@redhat.com wrote:
From: Martyn Taylor mtaylor@redhat.com
bin/aeolus-cleanup | 35 +++++++++++++++++++++++++++++++++-- 1 files changed, 33 insertions(+), 2 deletions(-)
diff --git a/bin/aeolus-cleanup b/bin/aeolus-cleanup index a2ff45f..22387a1 100644 --- a/bin/aeolus-cleanup +++ b/bin/aeolus-cleanup @@ -1,4 +1,35 @@ #!/bin/sh +usage() +{ +cat << EOF
+USAGE: +aeolus-cleanup [-d|--debug] [-h|--help] [-v|--verbose]
+OPTIONS:
- -h | --help Show this message.
- -d | --debug Debug logging mode.
- -v | --verbose Verbose logging mode.
+EOF +}
+args=`getopt -o :hdv --long help,debug,verbose -- "$@"` +if test $? != 0
then
usage
exit 1
+fi
+eval set -- $args +while true ; do
case "$1" in
-h|--help) usage ; exit 1 ; shift ;;
-d|--debug) LOGLEVEL="--debug" ; shift ;;
-v|--verbose) LOGLEVEL="--verbose" ; shift ;;
--) shift ; break ;;
*) usage ; exit 1 ;;
esac
+done
export FACTER_AEOLUS_ENABLE_HTTPS=true export FACTER_AEOLUS_ENABLE_SECURITY=false @@ -6,5 +37,5 @@ puppet /usr/share/aeolus-configure/modules/aeolus/manifests/defaults.pp \ --modulepath=/usr/share/aeolus-configure/modules/ \ --external_nodes '/usr/sbin/aeolus-node cleanup' --node_terminus exec \ --logdest=/var/log/aeolus-configure/aeolus-configure.log \
--logdest=console
--logdest=console \
$LOGLEVEL
-- 1.7.4
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
Francesco,
Yes, aeolus-cleanup should deffinately log to confirm that everything has been "cleaned up" properly, and crucially for debugging purposes.
It has a separate log file to aeolus-configure: /var/log/aeolus-configure/aeolus-cleanup
Cheers
Martyn
----- Original Message ----- From: "Francesco Vollero" fvollero@redhat.com To: mtaylor@redhat.com Cc: aeolus-devel@fedorahosted.org Sent: Friday, 3 June, 2011 10:30:41 AM Subject: Re: [PATCH configure 2/2] added options for verbose/debug logging on cleanup
On Thu, Jun 02, 2011 at 05:17:29PM +0200, Francesco Vollero wrote:
Ack'd. Work perfectly now. A+ to you martyn :)
Martyn sorry but Justin Clift pointed me to a curious thing, is normal that even the cleanup gonna log on aeolus-configure?
Cheers, Francesco
On Thu, Jun 02, 2011 at 04:05:40PM +0100, mtaylor@redhat.com wrote:
From: Martyn Taylor mtaylor@redhat.com
bin/aeolus-cleanup | 35 +++++++++++++++++++++++++++++++++-- 1 files changed, 33 insertions(+), 2 deletions(-)
diff --git a/bin/aeolus-cleanup b/bin/aeolus-cleanup index a2ff45f..22387a1 100644 --- a/bin/aeolus-cleanup +++ b/bin/aeolus-cleanup @@ -1,4 +1,35 @@ #!/bin/sh +usage() +{ +cat << EOF
+USAGE: +aeolus-cleanup [-d|--debug] [-h|--help] [-v|--verbose]
+OPTIONS:
- -h | --help Show this message.
- -d | --debug Debug logging mode.
- -v | --verbose Verbose logging mode.
+EOF +}
+args=`getopt -o :hdv --long help,debug,verbose -- "$@"` +if test $? != 0
then
usage
exit 1
+fi
+eval set -- $args +while true ; do
case "$1" in
-h|--help) usage ; exit 1 ; shift ;;
-d|--debug) LOGLEVEL="--debug" ; shift ;;
-v|--verbose) LOGLEVEL="--verbose" ; shift ;;
--) shift ; break ;;
*) usage ; exit 1 ;;
esac
+done
export FACTER_AEOLUS_ENABLE_HTTPS=true export FACTER_AEOLUS_ENABLE_SECURITY=false @@ -6,5 +37,5 @@ puppet /usr/share/aeolus-configure/modules/aeolus/manifests/defaults.pp \ --modulepath=/usr/share/aeolus-configure/modules/ \ --external_nodes '/usr/sbin/aeolus-node cleanup' --node_terminus exec \ --logdest=/var/log/aeolus-configure/aeolus-configure.log \
--logdest=console
--logdest=console \
$LOGLEVEL
-- 1.7.4
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
Ack'd
Cheers, Francesco
On Thu, Jun 02, 2011 at 04:05:39PM +0100, mtaylor@redhat.com wrote:
From: Martyn Taylor mtaylor@redhat.com
bin/aeolus-configure | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/bin/aeolus-configure b/bin/aeolus-configure index b4c1f39..310b76e 100644 --- a/bin/aeolus-configure +++ b/bin/aeolus-configure @@ -13,7 +13,14 @@ OPTIONS: EOF }
-eval set -- `getopt -o hdv --long help,debug,verbose -- "$@"` +args=`getopt -o :hdv --long help,debug,verbose -- "$@"` +if test $? != 0
then
usage
exit 1
+fi
+eval set -- $args while true ; do case "$1" in -h|--help) usage ; exit 1 ; shift ;; -- 1.7.4
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
aeolus-devel@lists.fedorahosted.org