2 # Map drawing script file
4 # Command : server { ... }
5 # Description : Specifies a server to connect, fetch statistics, draw the
6 # server on map and to show its status on the map. See the
7 # example server command below for all parameters of this
10 # Command : loadmap { filename = <filename>; };
11 # Example : loadmap { filename = "world_map.ppm"; };
12 # Description : Load the source bitmap image file to be used as the map
14 # Command : writemap { filename = <filename>; };
15 # Example : writemap { filename = "map.ppm"; };
16 # Description : Write the target bitmap image file
18 # Command : writemaphtml { filename = <filename>; image = <filename>;
19 # cut_lat = <lat>; cut_lon = <lon>; };
20 # Example : writemaphtml { filename = "htmlmap.map"; image = "map.jpg"; };
21 # Description : Write the gathered information as as HTML map page. This
22 # allows the user to click the specified points of URLs.
23 # The writemaphtml_url parameter in server will specify the
24 # URL that will be used in the HTML map. If omitted the
25 # filename created by writehml command is used. The <cut_lat>
26 # and <cut_lon> are specified if the <image> is a portion of
27 # the original map image. In this case the lat and lon specify
28 # which portion it is.
30 # Command : writehtml { filename = <filename>; class = <class>; };
31 # Example : writehtml { filename = "index.html"; };
32 # Description : Write the gathered information as HTML pages. Every server
33 # command will have their own HTML file. The filename is
34 # based on the hostname of the server. The index HTML file
35 # will include list of the servers. The generated HTML files
36 # are quite raw and are intended to be embedded into user's
37 # own website. If <class> is defined the it is used as the
38 # CSS class in the created HTML page.
40 # Command : cut { lat = <lat>; lon = <lon>; width = <width>;
41 # height = <height>; filename = <filename>; };
42 # Example : cut { lat = "20"; lon = "5"; width = "1000"; height = "700";
43 # filename = "map_chunk.ppm"; };
44 # Description : Cuts a chunk from the source image at specified location.
45 # The chunk will be <width> * <height> pixels in size. The
46 # <filename> is the output bitmap file where the chunk is saved.
48 # Command : rectangle { lat = <lat>; lon = <lon>; color = <color>;
49 # label = <label>; lposx = <x>; lposy = <y>;
50 # lcolor = <label color>; };
51 # Example : rectangle { lat = "-31 30"; lon = "0"; color = "0 0 255";
52 # label = "text"; lposx = "-10", lposy = "15"; };
53 # Description : Draws a rectangle at specified location. The center of the
54 # rectangle will be at specified location. If the <label>
55 # is specified, that text will appear with the rectangle at the
56 # <lposx> and <lposy> pixel location in relation to the
57 # rectangle. If <lcolor> is omitted the <color> is used.
59 # Command : circle { lat = <lat>; lon = <lon>; color = <color>;
60 # label = <label>; lposx = <x>; lposy = <y>;
61 # lcolor = <label color>; };
62 # Example : circle { lat = "31 30"; lon = "0"; color = "255 255 255"; };
63 # Description : Draws a circle at specified location. The center of the
64 # circle will be at specified location. If the <label>
65 # is specified, that text will appear with the circle at the
66 # <lposx> and <lposy> pixel location in relation to the
67 # circle. If <lcolor> is omitted the <color> is used.
69 # Command : line { a_lat = <lat>; a_lon = <lon>; b_lat = <lat>;
70 # b_lon = <lon>; width = <width>; color = <color>; };
71 # Description : Draws a straight line between points a and b. The <width>
72 # is line width in pixels. If omitted, default is 1.
74 # Command : text { lat = <lat>; lon = <lon>; color = <color>;
76 # Example : text { lat = "63 42 13", lon = "23 17 34", color = "0 0 255";
77 # text = "This is an example text"; };
78 # Description : Prints the text <text> at the specified location
80 # The <lat> is in format DD MM SS, where DD is degrees, MM minutes, and
81 # SS seconds. If DD is positive the latitude is north bound, if negative
82 # it is south bound. At least DD must be specified.
84 # The <lon> is in format DD MM SS, where DD is degrees, MM minutes, and
85 # SS seconds. If DD is positive the longitude is east bound, if negative
86 # it is west bound. At least DD must be specified.
88 # The <color> is in format RRR GGG BBB, where RRR is red, GGG green and
89 # BBB blue, between 0 - 255.
92 loadmap { filename = "map.ppm"; };
93 writemaphtml { filename = "map.html"; image = "map.jpg"; };
97 hostname = "eample.server.com";
100 public_key = "example.server.com_706.pub";
106 # Connection parameters
108 connect_timeout = "30";
110 # Statistics to fetch
118 cell_channels = true;
124 all_server_ops = true;
125 all_router_ops = true;
127 # Fetch message of the day
130 # Status colors when server is either up or down
131 up_color = "150 200 190";
132 down_color = "150 0 0";
133 up_text_color = "60 200 200";
134 down_text_color = "150 0 0";
136 # Draw this server on the map
137 rectangle { lat = "36 00"; lon = "25 00";
138 label = "example.server.com";
139 lposx = "-30"; lposy = "10"; };
142 writemap { filename = "testi2.ppm"; };