Sure! It's basically straight from the sample-config.tcl. Here goes:
---
set httpport 8000
set hostname localhost
set address 127.0.0.1
set servername "funk"
set serverdesc "server of funk"
set homedir [file dirname [ns_info config]]
set bindir [file dirname [ns_info nsd]]
set pageroot ${homedir}/servers/${servername}/pages
set directoryfile
index.adp,index.html,index.htm,index.xhtml,index.xht,index.tcl
set shlibext [info sharedlibextension]
#
# Global server parameters
#
ns_section "ns/parameters"
ns_param home $homedir
ns_param debug false
#
# I18N Parameters
#
#ns_param HackContentType false ;# automatic adjustment of response
# content-type header to include
charset
# This defaults to True.
ns_param OutputCharset iso-8859-1 ;# Default output charset. When
none specified,
# no character encoding of
output is performed.
ns_param URLCharset iso-8859-1 ;# Default Charset for Url
Encode/Decode.
# When none specified, no
character set encoding
# is performed.
#ns_param PreferredCharsets { utf-8 iso-8859-1 } ;# This parameter
supports output
# encoding arbitration.
#
# MIME types.
#
# Note: AOLserver already has an exhaustive list of MIME types, but in
# case something is missing you can add it here.
#
ns_section "ns/mimetypes"
ns_param default "*/*" ;# MIME type for unknown extension.
ns_param noextension "*/*" ;# MIME type for missing extension.
#ns_param ".xls" "application/vnd.ms-excel"
#
# I18N Mime-types; define content-type header values
# to be mapped from these file-types.
# Note that you can map file-types of adp files to
control
# the output encoding through mime-type specificaion.
# Remember to add an adp mapping for that extension.
#
ns_param .adp "text/html; charset=iso-8859-1"
ns_param .u_adp "text/html; charset=UTF-8"
ns_param .gb_adp "text/html; charset=GB2312"
ns_param .sjis_html "text/html; charset=shift_jis"
ns_param .sjis_adp "text/html; charset=shift_jis"
ns_param .gb_html "text/html; charset=GB2312"
#
# I18N File-type to Encoding mappings
#
ns_section "ns/encodings"
ns_param .utf_html "utf-8"
ns_param .sjis_html "shiftjis"
ns_param .gb_html "gb2312"
ns_param .big5_html "big5"
ns_param .euc-cn_html "euc-cn"
#
# Note: you will need to include file-type to encoding mappings
# for ANY source files that are to be used, to allow the
# server to handle them properly. E.g., the following
# asserts that the GB-producing .adp files are themselves
# encoded in GB2312 (this is not simply assumed).
#
ns_param .gb_adp "gb2312"
#
# Thread library (nsthread) parameters
#
ns_section "ns/threads"
#ns_param stacksize [expr 128*1024] ;# Per-thread stack size.
############################################################
#
# Server-level configuration
#
# There is only one server in AOLserver, but this is helpful when multiple
# servers share the same configuration file. This file assumes that only
# one server is in use so it is set at the top in the "server" Tcl
variable.
# Other host-specific values are set up above as Tcl variables, too.
#
ns_section "ns/servers"
ns_param $servername $serverdesc
#
# Server parameters
#
ns_section "ns/server/${servername}"
ns_param directoryfile $directoryfile
ns_param pageroot $pageroot
ns_param enabletclpages true
#
# Server-level I18N Parameters can be specified here, to override
# the global ones for this server. These are:
# HackContentType
# OutputCharset
# URLCharset
# See the global parameter I18N section for a description of these.
#
#
# Scaling and Tuning Options
#
# Note: These values aren't necessarily the defaults.
#
#ns_param connsperthread 0 ;# Normally there's one conn per
thread
#ns_param flushcontent false ;# Flush all data before returning
#ns_param maxconnections 100 ;# Max connections to put on queue
#ns_param maxdropped 0 ;# Shut down if dropping too many
conns
#ns_param maxthreads 20 ;# Tune this to scale your server
#ns_param minthreads 0 ;# Tune this to scale your server
#ns_param threadtimeout 120 ;# Idle threads die at this rate
#
# ADP (AOLserver Dynamic Page) configuration
#
ns_section "ns/server/${servername}/adp"
ns_param map "/*.adp" ;# Extensions to parse as ADP's.
# I18N Note: will need to define I18N specifying mappings of ADP's
here as well.
ns_param map "/*.u_adp"
ns_param map "/*.gb_adp"
ns_param map "/*.sjis_adp"
#ns_param map "/*.html" ;# Any extension can be mapped.
ns_param enableexpire false ;# Set "Expires: now" on all ADP's.
ns_param enabledebug false ;# Allow Tclpro debugging with
"?debug".
# ADP special pages
#ns_param errorpage ${pageroot}/errorpage.adp ;# ADP error page.
#
# Socket driver module (HTTP) -- nssock
#
ns_section "ns/server/${servername}/module/nssock"
ns_param port $httpport
ns_param hostname $hostname
ns_param address $address
# Fast Path --
#
# Fast path configuration is used to configure options used for serving
# static content, and also provides options to automatically display
# directory listings.
#
# Parameters:
#
# cache Boolean. Enable cache for normal URLs.
# Optional, default is false.
# cachemaxsize Integer. Size of fast path cache.
# Optional, default is 5120000.
# cachemaxentry Integer. Largest file size allowed in cache.
# Optional, default is cachemaxsize / 10.
# mmap Boolean. Use mmap() for cache.
# Optional, default is false.
# directoryfile String. Directory index/default page to
# look for. Optional, default is directoryfile
# parameter set in ns/server/${servername} section.
# directorylisting String. Directory listing style. Optional,
# Can be "fancy" or "simple".
# directoryproc String. Name of Tcl proc to use to display
# directory listings. Optional, default is to use
# _ns_dirlist. You can either specify directoryproc,
# or directoryadp - not both.
# directoryadp String. Name of ADP page to use to display
# directory listings. Optional. You can either
# specify directoryadp or directoryproc - not both.
#
# Example:
#
# ns_section "ns/server/${servername}/fastpath"
# ns_param directorylisting fancy
#
# See also:
#
# /aolserver/nsd/fastpath.c
# /aolserver/tcl/fastpath.tcl
ns_section "ns/server/${servername}/fastpath"
ns_param directorylisting fancy
#
# Access log -- nslog
#
ns_section "ns/server/${servername}/module/nslog"
ns_param rolllog true ;# Should we roll log?
ns_param rollonsignal true ;# Roll log on SIGHUP.
ns_param rollhour 0 ;# Time to roll log.
ns_param maxbackup 5 ;# Max number to keep around when
rolling.
ns_param logreqtime true ;# Log the execution time of request
#
# Modules to load
#
ns_section "ns/server/${servername}/modules"
ns_param nssock ${bindir}/nssock${shlibext}
ns_param nslog ${bindir}/nslog${shlibext}
ns_param nsdb ${bindir}/nsdb${shlibext}
#ns_param nscgi ${bindir}/nscgi${shlibext}
#ns_param nsperm ${bindir}/nsperm${shlibext}
---
Dossy Shiobara wrote:
On 2004.07.27, Kevin S. Davis <[EMAIL PROTECTED]> wrote:
How do I enable tcl pages on Mac OS X?
[...]
The same config.tcl works fine on WinXP and I frequently use
enabletclpages on Linux.
Could you post your entire config .tcl script for us to review? Blot
out any passwords, but otherwise post it as-is.
-- Dossy
--
Dossy Shiobara mail: [EMAIL PROTECTED]
Panoptic Computer Network web: http://www.panoptic.com/
"He realized the fastest way to change is to laugh at your own
folly -- then you can let go and quickly move on." (p. 70)
--
AOLserver - http://www.aolserver.com/
To Remove yourself from this list, simply send an email to <[EMAIL PROTECTED]> with the
body of "SIGNOFF AOLSERVER" in the email message. You can leave the Subject: field of
your email blank.
--
AOLserver - http://www.aolserver.com/
To Remove yourself from this list, simply send an email to <[EMAIL PROTECTED]> with the
body of "SIGNOFF AOLSERVER" in the email message. You can leave the Subject: field of
your email blank.