]> granicus.if.org Git - icinga2/commitdiff
Change Vagrant VM welcome page to a more friendly one.
authorMichael Friedrich <michael.friedrich@netways.de>
Tue, 27 May 2014 14:20:33 +0000 (16:20 +0200)
committerMichael Friedrich <michael.friedrich@netways.de>
Tue, 27 May 2014 14:21:10 +0000 (16:21 +0200)
Fixes #6334

.vagrant-puppet/files/etc/httpd/conf.d/icinga2-doc.conf [deleted file]
.vagrant-puppet/files/var/www/html/icinga_wall.png [new file with mode: 0644]
.vagrant-puppet/files/var/www/html/index.html [new file with mode: 0644]
.vagrant-puppet/manifests/default.pp

diff --git a/.vagrant-puppet/files/etc/httpd/conf.d/icinga2-doc.conf b/.vagrant-puppet/files/etc/httpd/conf.d/icinga2-doc.conf
deleted file mode 100644 (file)
index 50bb2f6..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-Alias /icinga2-doc "/usr/share/doc/icinga2/htdocs"
-
-RewriteEngine On
-RewriteRule ^/$ /icinga2-doc/#vagrant [NE,L,R=301]
-
diff --git a/.vagrant-puppet/files/var/www/html/icinga_wall.png b/.vagrant-puppet/files/var/www/html/icinga_wall.png
new file mode 100644 (file)
index 0000000..fb0130e
Binary files /dev/null and b/.vagrant-puppet/files/var/www/html/icinga_wall.png differ
diff --git a/.vagrant-puppet/files/var/www/html/index.html b/.vagrant-puppet/files/var/www/html/index.html
new file mode 100644 (file)
index 0000000..fdb5cf0
--- /dev/null
@@ -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>
index 21b789ede1c4c24b12da0b3dbc13685e7469503d..cf9fbc22e85ae0687da5d18918e8d2629943596a 100644 (file)
@@ -5,13 +5,29 @@ include icinga2-icinga-web
 include nagios-plugins
 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',
-  require => [ Package['apache'], Package['icinga2-doc'] ],
-  notify => Service['apache']
+
+####################################
+# Start page at http://localhost/
+####################################
+
+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':
   ensure => 'installed'
 }