Skip to content

Commit cc2ff6b

Browse files
authored
Small corrections (viper0131#36)
1 parent ab07e65 commit cc2ff6b

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

README.md

-7
Original file line numberDiff line numberDiff line change
@@ -111,13 +111,6 @@ If you want to map another local directory (e.g. for backup or check scripts):
111111
--volume <localdir>:/opt/backup
112112
```
113113

114-
If use external the volume you can used this volume by second. All
115-
settings, users, groups and etc will be saved.
116-
117-
>*Note*: The mode with exist volume not support multisite
118-
>feature. Only one site - one container will be works.
119-
120-
121114
## Test installation
122115

123116
Check the status of check_mk using:

bootstrap.sh

+7-1
Original file line numberDiff line numberDiff line change
@@ -4,26 +4,31 @@ BASE_OMD="/opt/omd/sites"
44

55
# Init check_mk instance
66
if [ ! -d "${BASE_OMD}/${CMK_SITE}" ] ; then
7+
8+
# Create new site
79
omd create ${CMK_SITE}
810
omd config ${CMK_SITE} set APACHE_TCP_ADDR 0.0.0.0
911
htpasswd -b -m /omd/sites/${CMK_SITE}/etc/htpasswd cmkadmin ${CMK_PASSWORD}
1012
/opt/redirector.sh ${CMK_SITE} > /omd/sites/${CMK_SITE}/var/www/index.html
1113

1214
# Save omd record about tmpfs for second use
1315
grep omd /etc/fstab > ${BASE_OMD}/${CMK_SITE}/.fstab.tmpfs
16+
1417
else
18+
1519
# Create user and group for using existing site with new container
1620
useradd -M -c "OMD site ${CMK_SITE}" -b "/omd/sites" -U -G omd ${CMK_SITE}
1721
usermod -aG ${CMK_SITE} apache
1822
chown -R ${CMK_SITE}:${CMK_SITE} ${BASE_OMD}/${CMK_SITE}
23+
1924
# Restore tmpfs
2025
cat ${BASE_OMD}/${CMK_SITE}/.fstab.tmpfs >> /etc/fstab
2126
mount tmpfs
2227
omd enable ${CMK_SITE}
2328
fi
2429

2530

26-
# This link needs always
31+
# This link is always needed
2732
ln -s "/omd/sites/${CMK_SITE}/var/log/nagios.log" /var/log/nagios.log
2833

2934

@@ -45,3 +50,4 @@ chown root:mail $CFGFILE
4550

4651
# Start check_mk
4752
omd start && tail -f /var/log/nagios.log
53+

0 commit comments

Comments
 (0)