Browse files

Now using jQuery Mobile 1.0a2

  • Loading branch information...
1 parent ce603fb commit 79992e5b80fbca535159fca8a492cd45c518a1b6 @bivald committed Nov 15, 2010
View
12 README
@@ -1,6 +1,8 @@
Munin Mobile
By: Niklas Bivald
+www.munin-mobile.com
+
INTRODUCTION
Munin Mobile is a mobile template for Munin, using jquery-mobile. This allows
your Munin installations to be easily monitored with your smartphone.
@@ -29,19 +31,21 @@ Munin user:
*/5 * * * * /etc/munin/update-mobile.sh
After installation, you should have a mobile-subfolder in your munin
-(yourdomain.com/munin/mobile). Also, the CSS/JS right now assumes you have
-munin in a subfolder (yourdomain.com/munin). This will be fixed in upcoming releases.
+(yourdomain.com/munin/mobile).
DEPENDENCIES
We're currently resizing all images "manually", mainly because I haven't found any
good way to do this in munin without updating the munin-nodes.
-We're currently using ImageMagick to do this, to install:
+We're currently using ImageMagick to do this, so install:
apt-get install imagemagick
If someone could point me to how to resize munin graphs natively on master, I would
be very happy.
SCREENSHOTS
-... will follow
+You will find screenshots on http://www.munin-mobile.com/screenshots/
+
+DEMO
+Demo can be found on http://demo.munin-mobile.com
View
12 install.sh
@@ -17,10 +17,16 @@ echo ""
echo "############################################################"
echo ""
-if [ $1 == "a" ]
+if [ $1 ]
then
- echo "- Auto-continue supplied as argument"
- continue='Y'
+ if [ $1 == "--auto" ]
+ then
+ echo "- Auto-continue supplied as argument"
+ continue='Y'
+ else
+ echo -n "Continue? [Y]: "
+ read continue
+ fi
else
echo -n "Continue? [Y]: "
read continue
View
12 mobile-www/css/munin-mobile.css
@@ -97,3 +97,15 @@
font-weight: normal;
font-size: 13px;
}
+
+/* footer */
+.ui-mobile .footer {
+ font-size: 10px;
+ text-align: center;
+}
+
+.ui-mobile .footer a {
+ color: inherit;
+ font-weight: inherit;
+}
+
View
34 mobile-www/js/munin-mobile.js
@@ -1,44 +1,10 @@
-$(document).ready(function() {
-
- // 495,271
- //height =
- //alert( $('.ui-li-thumb').parent().width() )
-
- //alert($('.ui-li-thumb').parent().width())
- //alert($(window).width())
-
- /*
- should_jump = document.location.href.match(/\?jump\=([a-zA-Z0-9]+)/);
-
- if(should_jump != null) {
- if($('#'+should_jump[1]).length > 0) {
- pos = $('#'+should_jump[1]).position();
- setTimeout("$('body').scrollTop(pos['top'])",250)
- }
- }
-
- */
- //checkJump()
-});
-
$('div').live('pagecreate',function(){
$('#quickjump span').click(function() {
doJump($(this).html())
});
- /*
- if ( $('.imgday').parent().width() > 0 ) { // if it's 0 we have full width and it hasn't been affected by max-width
- ratio = $('.imgday').parent().width()/495; // 0.547475, ($('.ui-li-thumb').parent().width() = width the images will be when loaded, since they have max width 100%)
- if(ratio < 1) {
- height = 271*ratio;
- $('.imgday').css('height',height+'px');
- }else{
- $('.imgday').css('height','272px');
- }
- }
- */
});
function doJump(whereTo) {
View
12 templates-mobiles/munin-domainview.tmpl
@@ -2,11 +2,11 @@
<html>
<head>
<title><TMPL_VAR NAME="DOMAIN"></title>
- <link rel="stylesheet" href="../css/jquery.mobile-1.0a1.min.css" />
- <script src="../js/jquery-1.4.3.min.js"></script>
- <script src="../js/jquery.mobile-1.0a1.min.js"></script>
- <script src="../js/munin-mobile.js"></script>
- <link rel="stylesheet" href="../css/munin-mobile.css" />
+ <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.css" />
+ <script src="http://code.jquery.com/jquery-1.4.4.min.js"></script>
+ <script src="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.js"></script>
+ <script src="js/munin-mobile.js"></script>
+ <link rel="stylesheet" href="css/munin-mobile.css" />
<meta http-equiv="content-type" content="application/xhtml+xml; charset=iso-8859-1" />
<meta name="author" content="Auto-generated by Munin (mobile)" />
@@ -36,7 +36,7 @@
</TMPL_LOOP>
-
+<p class="footer">Munin + <a href="http://www.munin-mobile.com">Munin Mobile</a> by <a href="http://www.bivald.com">bivald</a></p>
</div>
<script src="/munin/mobile/js/munin-mobile.js"></script>
</body>
View
11 templates-mobiles/munin-nodeview.tmpl
@@ -2,10 +2,11 @@
<html>
<head>
<title><TMPL_VAR ESCAPE="HTML" NAME="NODE"></title>
- <link rel="stylesheet" href="../css/jquery.mobile-1.0a1.min.css" />
- <script src="../js/jquery-1.4.3.min.js"></script>
- <script type="text/javascript" src="../js/jquery.mobile-1.0a1.min.js"></script>
- <link rel="stylesheet" href="../css/munin-mobile.css" />
+ <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.css" />
+ <script src="http://code.jquery.com/jquery-1.4.4.min.js"></script>
+ <script src="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.js"></script>
+ <script src="js/munin-mobile.js"></script>
+ <link rel="stylesheet" href="css/munin-mobile.css" />
<meta http-equiv="content-type" content="application/xhtml+xml; charset=iso-8859-1" />
<meta name="author" content="Auto-generated by Munin" />
</head>
@@ -20,7 +21,7 @@
<div data-role="content">
<ul data-role="listview" class="show_all_graphs" data-theme="c">
- <li><a href="/munin/mobile/">Back to all domains</a></li>
+ <li><a href="../">Back to all domains</a></li>
</ul>
<ul data-role="listview">
<TMPL_LOOP NAME="CATEGORIES">
View
7 templates-mobiles/munin-overview.tmpl
@@ -2,9 +2,9 @@
<html>
<head>
<title>Munin :: overview</title>
- <link rel="stylesheet" href="css/jquery.mobile-1.0a1.min.css" />
- <script src="js/jquery-1.4.3.min.js"></script>
- <script src="js/jquery.mobile-1.0a1.min.js"></script>
+ <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.css" />
+ <script src="http://code.jquery.com/jquery-1.4.4.min.js"></script>
+ <script src="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.js"></script>
<script src="js/munin-mobile.js"></script>
<link rel="stylesheet" href="css/munin-mobile.css" />
@@ -29,6 +29,7 @@
</TMPL_LOOP>
</ul>
</TMPL_LOOP>
+<p class="footer">Munin + <a href="http://www.munin-mobile.com">Munin Mobile</a> by <a href="http://www.bivald.com">bivald</a></p>
</div>
</body>
</html>
View
21 templates-mobiles/munin-serviceview.tmpl
@@ -2,11 +2,12 @@
<html>
<head>
<title><TMPL_VAR ESCAPE="HTML" NAME="SERVICE"> (<TMPL_VAR NAME="NODE">)</title>
- <link rel="stylesheet" href="../css/jquery.mobile-1.0a1.min.css" />
- <script src="../js/jquery-1.4.3.min.js"></script>
- <script type="text/javascript" src="../js/jquery.mobile-1.0a1.min.js"></script>
- <script src="../js/munin-mobile.js"></script>
- <link rel="stylesheet" href="../css/munin-mobile.css" />
+ <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.css" />
+ <script src="http://code.jquery.com/jquery-1.4.4.min.js"></script>
+ <script src="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.js"></script>
+ <script src="js/munin-mobile.js"></script>
+ <link rel="stylesheet" href="css/munin-mobile.css" />
+
<meta http-equiv="content-type" content="application/xhtml+xml; charset=iso-8859-1" />
<meta name="author" content="Auto-generated by Munin" />
@@ -22,9 +23,9 @@
<div data-role="content" id="node-serviceview">
<ul data-role="listview" class="show_all_graphs" data-theme="c">
- <li><a href="/munin/mobile/">Back to all domains</a></li>
- <li><a href="/munin/mobile/<TMPL_VAR NAME="DOMAIN">/">List of all graphs on <TMPL_VAR NAME="DOMAIN"></a></li>
- <li><a href="/munin/mobile/<TMPL_VAR NAME="DOMAIN">/<TMPL_VAR NAME="NODE">.html">Show all graphs (actual images) on <TMPL_VAR NAME="DOMAIN"></a></li>
+ <li><a href="../">Back to all domains</a></li>
+ <li><a href="../<TMPL_VAR NAME="DOMAIN">/">List of all graphs on <TMPL_VAR NAME="DOMAIN"></a></li>
+ <li><a href="../<TMPL_VAR NAME="DOMAIN">/<TMPL_VAR NAME="NODE">.html">Show all graphs (actual images) on <TMPL_VAR NAME="DOMAIN"></a></li>
</ul>
<TMPL_LOOP NAME="SERVICES">
@@ -70,11 +71,9 @@
</table>
</TMPL_LOOP>
+ <p class="footer">Munin + <a href="http://www.munin-mobile.com">Munin Mobile</a> by <a href="http://www.bivald.com">bivald</a></p>
</div><!-- /content -->
- <div data-role="footer">
- <h4>Munin 1.2.6</h4>
- </div><!-- /header -->
</div><!-- /page -->
<script src="/munin/mobile/js/munin-mobile.js"></script>
</body>

0 comments on commit 79992e5

Please sign in to comment.