Change Vagrant VM welcome page to a more friendly one.

Fixes #6334
This commit is contained in:
Michael Friedrich 2014-05-27 16:20:33 +02:00
parent 8404eb6037
commit b50988b9ac
4 changed files with 125 additions and 10 deletions

View File

@ -1,5 +0,0 @@
Alias /icinga2-doc "/usr/share/doc/icinga2/htdocs"
RewriteEngine On
RewriteRule ^/$ /icinga2-doc/#vagrant [NE,L,R=301]

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View File

@ -0,0 +1,104 @@
<html>
<head>
<title>
Icinga 2 Demo Vagrant Box
</title>
<style type="text/css">
body {
top: 0px;
left: 0px;
height: 100%;
position: fixed;
background: #fff;
box-shadow: inset -5px 0 5px 0px #000;
width: 1024px;
padding-top: 20px;
overflow:scroll;
font-family: "Lucida Grande", "Lucida Sans Unicode", Verdana, Helvetica, Arial, sans-serif;
font-size: 0.72em;
color: #262625;
}
ul {
margin: 0;
padding: 0;
list-style: none;
}
li {
padding: 5px 10px;
}
table {
border:1px solid;
}
th {
border:1px solid;
}
td {
border:1px solid;
}
a:link, a:visited, a:active {
color: #0489B1;
text-decoration: underline;
}
a:hover {
color: #01A9DB;
text-decoration: underline;
}
h1 {
font-size: 1.5em;
}
h2 {
font-size: 1.2em;
padding-left: 10px;
}
h3 {
padding-left: 20px;
}
h4 {
padding-left: 30px;
}
.active {
background: #336699;
box-shadow: inset -5px 0px 10px -5px #000;
}
pre {
font-family: "courier new", courier, monospace;
font-size: 12px;
}
</style>
</head>
<img src="icinga_wall.png">
<h1>Welcome to the Icinga 2.x Cluster Demo Vagrant Box!</h1>
<h2>GUI</h2>
<p>
Available user interfaces.
</p>
<table>
<tr><th>GUI</th><th>Url</th><th>Credentials</th></tr>
<tr><td>Icinga Classic UI</td><td><a href="/icinga" target="_blank">/icinga</a></td><td>icingaadmin/icingaadmin</td></tr>
<tr><td>Icinga Web</td><td><a href="/icinga-web" target="_blank">/icinga-web</a></td><td>root/password</td></tr>
</table>
<h2>SSH</h2>
SSH is available through 'vagrant ssh $hostname' with passwordless sudo ('sudo -i').
<h1>Documentation</h1>
The official Icinga 2 documentation is available at <a href="https://docs.icinga.org">docs.icinga.org</a>.
</html>

View File

@ -5,13 +5,29 @@ include icinga2-icinga-web
include nagios-plugins include nagios-plugins
include nsca-ng include nsca-ng
# icinga 2 docs at /icinga2-doc
file { '/etc/httpd/conf.d/icinga2-doc.conf': ####################################
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/httpd/conf.d/icinga2-doc.conf', # Start page at http://localhost/
require => [ Package['apache'], Package['icinga2-doc'] ], ####################################
notify => Service['apache']
file { '/var/www/html/index.html':
source => 'puppet:////vagrant/.vagrant-puppet/files/var/www/html/index.html',
owner => 'apache',
group => 'apache',
require => Package['apache']
} }
file { '/var/www/html/icinga_wall.png':
source => 'puppet:////vagrant/.vagrant-puppet/files/var/www/html/icinga_wall.png',
owner => 'apache',
group => 'apache',
require => Package['apache']
}
####################################
# Misc
####################################
package { 'vim-enhanced': package { 'vim-enhanced':
ensure => 'installed' ensure => 'installed'
} }