diff --git a/configure b/configure index 03b3f204bda34a691f26a83216d8b1f3c89122c6..c3651d28fc04a2fe60eb12495f4444e34fc29ef2 100755 --- a/configure +++ b/configure @@ -1051,6 +1051,15 @@ else TBUSERSARCHIVE="$TBOPSEMAIL" fi +# Default OURDOMAIN to the domain name of the boss node +# This is gross beyond all description - autoconf changes m4's quote characters +# to '[' and ']', which prevents them from working in the sed expression below. +# So, we temporarily change them to something else then change them back. +# Note: In newer versions of autoconf, this can be done with 'quadrigraphs' +if test -z "$OURDOMAIN"; then + OURDOMAIN="`echo $BOSSNODE | sed -E -e 's/^[a-zA-Z0-9\-]+\.//'`" +fi + if test -z "$TBAUTHDOMAIN"; then TBAUTHDOMAIN=".$OURDOMAIN" fi @@ -1298,7 +1307,7 @@ fi # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # ./install, which can be erroneously created by make from ./install.sh. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:1302: checking for a BSD compatible install" >&5 +echo "configure:1311: checking for a BSD compatible install" >&5 if test -z "$INSTALL"; then if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 diff --git a/configure.in b/configure.in index d26d1e3a806da30e2290875fc6a49fcb9fab6e0d..e28d77d7ec67cd45e6520475206c556c2a5c3a21 100755 --- a/configure.in +++ b/configure.in @@ -196,6 +196,17 @@ else TBUSERSARCHIVE="$TBOPSEMAIL" fi +# Default OURDOMAIN to the domain name of the boss node +# This is gross beyond all description - autoconf changes m4's quote characters +# to '[' and ']', which prevents them from working in the sed expression below. +# So, we temporarily change them to something else then change them back. +# Note: In newer versions of autoconf, this can be done with 'quadrigraphs' +changequote(START, END)dnl +if test -z "$OURDOMAIN"; then + OURDOMAIN="`echo $BOSSNODE | sed -E -e 's/^[a-zA-Z0-9\-]+\.//'`" +fi +changequote([, ])dnl + if test -z "$TBAUTHDOMAIN"; then TBAUTHDOMAIN=".$OURDOMAIN" fi diff --git a/defs-example b/defs-example index d28bd9ba8512ad729e0f84a61b5696886eb18584..a0f1cec3c1372a64c776ed8aa904940631a71921 100644 --- a/defs-example +++ b/defs-example @@ -12,9 +12,6 @@ THISHOMEBASE=Example.Emulab.Net # Various domain and host names # -# Domain this testbed resides in -OURDOMAIN=example.emulab.net - # Host name of our web server (or host:port) WWWHOST=www.example.emulab.net diff --git a/doc/setup.txt b/doc/setup.txt index 0fbec7fe226fbb409a742676e2d96c29e616c650..f9e9a3442097cedd3921bcdf9941a18d42c359ae 100644 --- a/doc/setup.txt +++ b/doc/setup.txt @@ -119,7 +119,8 @@ and is generally helpful if things go wrong with the nameserver. SSL certificates - Our apache config file expects to find SSL certificates in: /usr/local/etc/apache/ssl.crt/www.<sitename>.crt and /usr/local/etc/apache/ssl.key/www.<sitename>.key -(where <sitename> is OURDOMAIN from the configure defs file.) +(where <sitename> is OURDOMAIN from the configure defs file, which defaults to +boss's domain name.) Generate a passwordless certificate (up to you if you want to get a 'real' one from Verisign, etc., or sign your own), and place the files from it in the above locations.