Changeset 3413 for pykota/trunk/docs/repykota.sgml
- Timestamp:
- 09/27/08 22:02:37 (16 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/docs/repykota.sgml
r2844 r3413 4 4 <title id="repykota">Create print quota usage reports with repykota</title> 5 5 <para>Last modified on $Date$</para> 6 6 7 7 <para> 8 8 To account for print usage is good, however there must be a way to easily … … 10 10 reports describing current usage for every user on every printer. 11 11 </para> 12 12 13 13 <sect1> 14 14 <title>Command line based Print Quota reports</title> 15 15 16 16 <para> 17 17 PyKota features a quota report generator, named <command>repykota</command>, 18 18 with which you can print the current state of the quota database. 19 19 </para> 20 20 21 21 <para> 22 22 <command>repykota</command> behaves differently when it is launched by a 23 23 <application>PyKota</application> administrator, compared to when it is launched by a normal user. 24 </para> 25 24 </para> 25 26 26 <para> 27 In the first case, the print quota report will contain current account balance, 27 In the first case, the print quota report will contain current account balance, 28 28 soft and hard limits, number of pages printed since last reset, total number 29 29 of pages printed, total paid, for possibly all users or all groups, depending 30 30 on command line options. 31 31 </para> 32 32 33 33 <para> 34 34 In the second case, i.e. when <command>repykota</command> is launched by 35 a normal user, the user will only be allowed to see informations about himself or 35 a normal user, the user will only be allowed to see informations about himself or 36 36 the groups he his a member of. 37 37 </para> 38 38 39 39 <para> 40 40 Any user can limit the report to only one or more printers, by specifying the 41 <literal>-P</literal> or <literal>--printer</literal> command line option, 41 <literal>-P</literal> or <literal>--printer</literal> command line option, 42 42 followed by one or more printer name or wildcard. If more than one printer name 43 43 or wildcard is used, they must be separated by commas. 44 44 </para> 45 45 46 46 <para> 47 47 Launching <command>repykota</command> with no arguments will generate 48 48 a complete print quota report, depending on what you are allowed to see. 49 49 </para> 50 50 51 51 <para> 52 52 Use the <literal>--help</literal> command line argument to learn what are 53 53 the different command line options available. 54 54 </para> 55 55 56 56 <sect2> 57 57 <title>Reference</title> … … 66 66 <arg>-P <replaceable>printername</replaceable></arg> 67 67 <arg>--printer <replaceable>printername</replaceable></arg> 68 </group> 68 </group> 69 69 <group choice="opt"> 70 70 <arg><replaceable>name1</replaceable></arg> … … 72 72 <arg><replaceable>...</replaceable></arg> 73 73 <arg><replaceable>nameN</replaceable></arg> 74 </group> 74 </group> 75 75 </cmdsynopsis> 76 76 </para> 77 77 </sect2> 78 78 </sect1> 79 79 80 80 <sect1> 81 81 <title>Web based Print Quota reports</title> 82 82 83 83 <para> 84 84 <application>PyKota</application> also features a CGI script to remotely access … … 88 88 correctly. 89 89 </para> 90 90 91 91 <para> 92 92 You may also want to copy the <acronym>CSS</acronym> stylesheets which are present in the … … 95 95 a nicer web interface. 96 96 </para> 97 97 98 98 <para> 99 99 You can find <command>printquota.cgi</command> in the <filename>pykota/cgi-bin</filename> 100 100 directory. Here's how to install it, provided that your web server's <filename>cgi-bin</filename> 101 101 directory is <filename>/usr/lib/cgi-bin</filename> : 102 <screen> 102 <screen> 103 103 port50-2:/home/jerome/pykota$ cp cgi-bin/printquota.cgi /usr/lib/cgi-bin 104 104 port50-2:/home/jerome/pykota$ chmod 755 /usr/lib/cgi-bin/printquota.cgi … … 112 112 must ensure that this user <emphasis>is not</emphasis> allowed to read <filename>~pykota/pykotadmin.conf</filename> 113 113 </para> 114 </note> 114 </note> 115 115 </para> 116 116 117 117 <para> 118 118 If you install the CGI script as described above, any user will be allowed to view the complete print … … 125 125 then there's no restriction on what may appear on the print quota report. 126 126 </para> 127 127 128 128 <para> 129 129 To automatically ask for an authentication dialog whenever the CGI script is accessed, you have to configure 130 your web server to do so. If your webserver is <ulink url="http://httpd.apache.org"><application>Apache</application></ulink>, then it's relatively easy. First you have to put 130 your web server to do so. If your webserver is <ulink url="http://httpd.apache.org"><application>Apache</application></ulink>, then it's relatively easy. First you have to put 131 131 <command>printquota.cgi</command> in its own subdirectory below your web server's <filename>cgi-bin</filename> 132 132 directory, for example in <filename>cgi-bin/PyKota/</filename>. Then use the <command>htpasswd</command> … … 140 140 authentication mechanism. 141 141 </para> 142 142 143 143 <para> 144 144 The detailed procedure to do all this is out of the scope of the present document, please refer to 145 <application>Apache</application>'s <ulink url="http://httpd.apache.org/docs-project/">documentation</ulink> 145 <application>Apache</application>'s <ulink url="http://httpd.apache.org/docs-project/">documentation</ulink> 146 146 for all the gory details. 147 147 </para>