jenkins/copy_puppet_logs.sh: prepare apache_config dir
This patch aims to manage apache_config directory before copying apache configuration from /etc. Otherwise, the job will fail since apache_config dir does not exist. Change-Id: Iafd27e9edf8865e462d4e33a2514afc8c466e290
This commit is contained in:
parent
a688f1e0f5
commit
e30670c1b2
@ -104,11 +104,13 @@ sudo cp /etc/sudoers $LOG_DIR/sudoers.txt
|
||||
if uses_debs; then
|
||||
apache_logs=/var/log/apache2
|
||||
if [ -d /etc/apache2/sites-enabled ]; then
|
||||
mkdir $LOG_DIR/apache_config
|
||||
sudo cp /etc/apache2/sites-enabled/* $LOG_DIR/apache_config
|
||||
fi
|
||||
elif is_fedora; then
|
||||
apache_logs=/var/log/httpd
|
||||
if [ -d /etc/apache2/httpd/conf.d ]; then
|
||||
if [ -d /etc/httpd/conf.d ]; then
|
||||
mkdir $LOG_DIR/apache_config
|
||||
sudo cp /etc/httpd/conf.d/* $LOG_DIR/apache_config
|
||||
fi
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user