old-www/LDP/lame/LAME/linux-admin-made-easy/web-server-administration.html

269 lines
3.9 KiB
HTML

<HTML
><HEAD
><TITLE
>Web Server and HTTP Caching Proxy Administration</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.63
"><LINK
REL="HOME"
TITLE="Linux Administration Made Easy"
HREF="index.html"><LINK
REL="UP"
TITLE="Custom Configuration and Administration Issues"
HREF="custom-config.html"><LINK
REL="PREVIOUS"
TITLE="Custom Configuration and Administration Issues"
HREF="custom-config.html"><LINK
REL="NEXT"
TITLE="Domain Name Server (DNS) Configuration and Administration"
HREF="domain-name-server.html"></HEAD
><BODY
CLASS="SECT1"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="NAVHEADER"
><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>Linux Administration Made Easy</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="custom-config.html"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
>Chapter 7. Custom Configuration and Administration Issues</TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="domain-name-server.html"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><DIV
CLASS="SECT1"
><H1
CLASS="SECT1"
><A
NAME="WEB-SERVER-ADMINISTRATION"
>7.1. Web Server and HTTP Caching Proxy Administration</A
></H1
><DIV
CLASS="WARNING"
><P
></P
><TABLE
CLASS="WARNING"
BORDER="1"
WIDTH="100%"
><TR
><TD
ALIGN="CENTER"
><B
>Warning</B
></TD
></TR
><TR
><TD
ALIGN="LEFT"
><P
>(WARNING: DISREGARD THIS SECTION!)</P
></TD
></TR
></TABLE
></DIV
><P
></P
><OL
TYPE="1"
><LI
><P
>Create an Internet user as per normal. The
<SPAN
CLASS="QUOTE"
>"shell"</SPAN
> account should be
``<TT
CLASS="LITERAL"
><TT
CLASS="FILENAME"
>/bin/bash</TT
></TT
>'' (as FTP requires a
valid shell).</P
></LI
><LI
><P
>``<TT
CLASS="LITERAL"
>cd /home ; chown root.root theuser</TT
>''
This makes <SPAN
CLASS="QUOTE"
>"theuser"</SPAN
>'s directory belong to root, for
security reasons.</P
></LI
><LI
><P
>``<TT
CLASS="LITERAL"
>cd /home/theuser ; mkdir www ; chown
theuser.theuser</TT
>'' This creates their <SPAN
CLASS="QUOTE"
>"www"</SPAN
>
directory, and sets ownership so they can read/write to
it.</P
></LI
><LI
><P
>``<TT
CLASS="LITERAL"
>echo "exit" &#62; .profile</TT
>''
This creates a ``<TT
CLASS="LITERAL"
><TT
CLASS="FILENAME"
>.profile</TT
></TT
>'' file
with the single line ``<TT
CLASS="LITERAL"
>exit</TT
>'' in it. If the user tries
to log in via telnet, they will get disconnected
immediately.</P
></LI
><LI
><P
>Do an ``<TT
CLASS="LITERAL"
>ls -l</TT
>'' and make sure there
are only 2 files in the directory (not including ``..'' and
``.''):</P
><P
></P
><UL
COMPACT="COMPACT"
><LI
STYLE="list-style-type: Bullet"
><P
><EM
>.profile</EM
> (owned by
root.root)</P
></LI
><LI
STYLE="list-style-type: Bullet"
><P
><EM
>www</EM
> (owned by
theuser.theuser)</P
></LI
></UL
><P
>All other files can be deleted (eg. ``<TT
CLASS="LITERAL"
>rm .less ; rm .lessrc</TT
>'')</P
></LI
><LI
><P
>If the user needs to have e-mail forwarding enabled you
could create a .forward file which simply has the proper e-mail as the
first and only line in the file.</P
></LI
></OL
><P
>That's it. The user can use FTP to update the pages.</P
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="custom-config.html"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="index.html"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="domain-name-server.html"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>Custom Configuration and Administration Issues</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="custom-config.html"
>Up</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Domain Name Server (DNS) Configuration and Administration</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>