This section assumes that you're running EwgieServer in a UNIX environment, although for other platforms the basics shouldn't be all that different. Once you've received, uncompressed, and unpacked the software distribution, you should have a directory called server that contains all the server-related files that you'll need. There is also a client subdirectory that contains the client files, and a docs subdirectory that contains the HTML documentation, and a utils subdirectory that contains optional files.
What's in the Distribution
Here's what should be in the server directory:
- A number of Java class files (they have
.class suffixes)
This is the Java code that makes everything work.
-
welcome.txt
This is a text-only startup message that appears when people connect to your server. If you remove this file, then no startup message will appear. This is a good place to put policies, pointers, discussion topics, etc. Text in this file will automatically wrap to the width of the viewer's screen.
-
server.conf
This file is the optional main configuration file.
-
.htaccess
This file is provided to prevent others from accessing these files publically via the Web. If your server does not recognize .htaccess files, you may want to set the equivalent permissions for this directory.
Here's what should be in the client directory:
-
Ewgie.html and other *.html files
These HTML templates can be used to put the client applet on your Web. Make sure you edit these first and change the host and port parameters to the machine and port you'll be running the server on. See the client options section for details.
- A number of Java class files (they have
.class and .zip suffixes)
This is the Java code that makes everything work.
-
ring.au
This is the sound people hear when you ring them. You can replace this with any sound in the Sun audio format, as long as it is called the same name.
-
widgets.gif
This is the tool panel for the whiteboard. Don't mess with it.
Here's what should be in the utils directory:
- A
sounds directory
A number of alternative alert sounds are provided that can server as client ring sounds. To use a sound, rename it ring.au and drop it into the client directory. The default sound is pingping.au.
-
EwgieLanguage.java
This file will allow you to internationalize the client and server. Read it for instructions on how to do this.
Running the Server
In order to run EwgieServer, you must have a Java virtual machine somewhere to execute the code. One way to do this is to go to java.sun.com and get the latest Java Developer's Kit, install it for your system and set it all up. Once that's done, all you have to do is type
java EwgieServer &
...and you're ready to rock 'n' roll.
When you first start the server, you'll notice that logging information goes to standard output. You can easily redirect this to another file:
java EwgieServer & >! access_log
Or you can specify a log file to create/append to using a command-line option or configuration file option.
If you will be setting up a client that is intended to connect with this server, make sure you configure the client parameters properly and set the host and port to that of the server.
Command-Line Options
Here are the EwgieServer command-line options in a nutshell:
usage: EwgieServer [-p #] [-m #] [-l file]
[-t file] [-w welcome] [-c file]
options: -p : the port to listen to
-m : the maximum number of clients to accept
-l : the log file to use
-t : the transcript file to use
-w : the welcome file to use
-c : the configuration file to use
...any unsupported option will return this usage message.
- -p number
This specifies the port to listen to. The default port is 1971.
- -m number
This specifies the maximum number of simultaneous connections (people) the server can support. The default maximum is 50 people.
- -l file
This is the log file to log transactions to. If the log file does not exist, it will be created. If it exists, it will be appended to.
- -t file
This is the transcript file which is a transcript of the activity on the server. If the file does not exist, it will be created. If it exists, it will be appended to. If the file name ends in ".html" or ".htm", the transcript will be formatted in HTML; otherwise the transcript will be in a text-only format. If you create a transcript, you may want to create a public link to it so others can see what's been going on. Private messages will not be shown in the transcript.
If the transcript file is in HTML, URLs that are typed will be automatically converted to hyperlinks and 8-bit characters will be converted to the proper HTML codes. See a sample transcript to see how it looks.
- -w file
This is the startup message displayed to people when they connect to the server. If it doesn't exist, no message will be displayed. This message must be a text-only file.
- -c configuration file
The configuration file to use. Command-line options override anything in the configuration file. There is no default configuration file, and the server does not look for one upon startup.
- -debug
This option will allow you to view all messages received by the server as well as any exceptions that are caught in the program. Use this if you experience recurring bugs in the server.
The Configuration File
The configuration file allows you to specify everything you can with command-line options and a little more. If you use command-line option with a configuration file, the command-line options will override anything in the file.
Here's what a sample file looks like:
# Administration file for EwgieServer
# These directives are case-insensitive
port 1971
maxClients 50
logFile access.log
welcomeFile welcome.txt
scriptFile script.txt
deny all
allow name Biff
allow address 192.100.
allow address 132.151.1.35
whiteboard on
password Biff mypassword
generalPassword somepassword
operatorPassword somepassword
timestamp 15
noNewRooms
makeRoom Lobby, This is the lobby, lobby.html
debug off
Blank lines and lines beginning with hash marks (#) are ignored. As you can see, the first five directives (from port to scriptFile) are pretty straightforward and self-explanatory, if you've already read what command-line options are available.
- allow and deny
deny and allow allow you to control in a basic fashion who connects to your server - by nickname and by IP address. Because there is no way to get the user's real name, these directives should be taken with a grain of salt. If you want slightly better control over who has access to your Ewgie server, you should make use of your Web server's access control mechanism instead of or in tandem with these directives.
You may also want to place the server and configuration file in a directory that is not accessible from the Web as an added precaution.
The allow/deny directives are parsed in order from the top down. Let's take the example above:
deny all
allow name Biff
allow address 192.100.
allow address 132.151.1.35
First, all access is denied to the server. Next, only the person with the nickname Biff (case-insensitive) is allowed into the server. After that, anyone coming from a computer with an address starting with 192.100 is allowed. After that, anyone coming from 132.151.1.35 is allowed.
Note that addresses must be number addresses and not names, and you can only perform matching on the beginnings of these addresses. Wildcards are not supported.
allow all
deny name Sue
deny address 198.95.251.30
This works in reverse - first, everyone is allowed access, then only those with the nickname Sue are denied access, then those coming from the address 198.95.251.30 are denied.
- whiteboard
If you wish the server to allow whiteboard communications, include this line in your configuration file:
whiteboard on
If you use this line:
whiteboard off
..then whiteboard communication will not be supported. This means that although members may open their whiteboards and draw on them, they will not be able to see what other people are doing. If you disable whiteboard communications in the server, you should note this in the server's welcome message.
- password, generalPassword, and operatorPassword
You can include a password directive in the configuration file, thereby closing the chat area to everyone except for those with passwords. If you typed in a line like this:
password John testpassword
...then only a user with the nickname John (case-insensitive) who entered the password testpassword (case-sensitive) is allowed to enter the chat area.
The generalPassword directive will require every user that has not been assigned a specific password to enter a common password before they can enter the chat area. Those already with specific passwords (as defined with the password directive) must still type in their specific passwords.
The operatorPassword directive specifies a password that is required to use the /shutdown and /notice commands. See the client documentation for how to use these commands.
If you use the password directives, note that passwords are not encrypted and are stored as plaintext. For this reason, it is highly recommended that you place the configuration file in an area that is not publicly accessible and that the passwords used by members are not used for anything else.
The server will enforce a minimum password length of eight characters.
- timestamp
If you are keeping a transcript of the chat activity, you can choose to have the server insert a time stamp (full time and date) at regular intervals. You must use the timestamp directive with the number of minutes between time stamps:
timestamp 15
This example inserts a time stamp every 15 minutes.
The time is given in Greenwich Mean Time and is inserted in HTML comments if the transcript format is in HTML.
- noNewRooms
By default chat members can create new rooms whenever they like. You can disable this option by including the noNewRooms directive in the configuration file.
- makeRoom
You can use this directive multiple times to make permanent rooms on the server - they cannot be removed by anybody. This is useful for setting up core topic areas. This directive is used like this:
makeRoom roomName, (roomTopic), (scriptFile)
A room name must be supplied. You can specify a room topic and a file to transcribe the room's activity to. If you do not supply a topic then anybody can change or remove the topic for that room. If you specify a script file the timestamp directive applies to it.
If you make multiple rooms, the first room you define with the makeRoom directive will be the server's default main room, the room everyone enters when they first connect to the server. The script for the main room can be specified in the scriptFile directive or as an argument to the first room you define. The room name, topic, and script arguments must be separated by a comma. Here's an example:
makeRoom Port of Entry, Welcome All!, entry.html
makeRoom Bazaar
makeRoom Bar and Grill, , bar.html
makeRoom Idle Chat, Nothing in particular
Anyone entering a server configured with these directives would first enter into the main room "Port of Entry" with the topic "Welcome All!". Any public activity in this room would be transcribed in the file entry.html. Anyone can change the topic for the room "Bazaar", which is not being transcribed.
The room "Bar and Grill" has no topic, but it is being recorded. Note that you can have multiple rooms being transcribed to different files. The room "Idle Chat" has the topic "Nothing in particular", which cannot be changed. None of these rooms can be removed.
Note that if the noNewRooms directive were specified no additional rooms could be made by chat members.
- debug
This directive can take the value on or off. Turning it on has the same effect as using the -debug command-line flag.
|