You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by se...@apache.org on 2024/09/10 16:58:59 UTC

(whimsy) branch master updated: Use the same port internally and externally

This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new 29e21070 Use the same port internally and externally
29e21070 is described below

commit 29e2107093ae426770e81c55ebbfea543d4017fa
Author: Sebb <se...@apache.org>
AuthorDate: Tue Sep 10 17:58:50 2024 +0100

    Use the same port internally and externally
---
 Dockerfile                | 5 ++++-
 compose.yaml              | 2 +-
 docker-config/whimsy.conf | 2 +-
 tools/mkconf.rb           | 2 +-
 4 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/Dockerfile b/Dockerfile
index 4bb662c6..a3d584f4 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -107,7 +107,10 @@ RUN DEBIAN_FRONTEND='noninteractive' apt-get install -y host
 
 WORKDIR /srv/whimsy
 RUN git config --global --add safe.directory /srv/whimsy
-EXPOSE 80
+
+# Use the same port internally and externally so SVN URLs are the same
+RUN sed -i -e 's/Listen 80/Listen 1999/' /etc/apache2/ports.conf
+EXPOSE 1999
 
 # Note: the httpd and LDAP config is now done in the container as part of startup
 # This is to avoid storing any credentials in the image
diff --git a/compose.yaml b/compose.yaml
index 5c95b8ad..15a35195 100644
--- a/compose.yaml
+++ b/compose.yaml
@@ -3,7 +3,7 @@ services:
     image: whimsy-web
     build: .
     ports:
-      - "1999:80"
+      - "1999:1999"
     environment:
       - "HOST_HOME=$HOME"
     volumes:
diff --git a/docker-config/whimsy.conf b/docker-config/whimsy.conf
index bc8637df..c962ec41 100644
--- a/docker-config/whimsy.conf
+++ b/docker-config/whimsy.conf
@@ -7,7 +7,7 @@
 # Managed by Puppet
 # ************************************
 #
-<VirtualHost *:80>
+<VirtualHost *:1999>
   ServerName whimsy.local
 
   ## Vhost docroot
diff --git a/tools/mkconf.rb b/tools/mkconf.rb
index 1963e2c6..e0c727b5 100755
--- a/tools/mkconf.rb
+++ b/tools/mkconf.rb
@@ -28,7 +28,7 @@ conf.sub! 'SetEnv HOME /var/www',''"SetEnv HOME /var/www
 SetEnv LANG C.UTF-8
 SetEnv LC_ALL C.UTF-8"''
 
-conf.sub! 'VirtualHost *:443', 'VirtualHost *:80'
+conf.sub! 'VirtualHost *:443', 'VirtualHost *:1999'
 conf.sub! /ServerName whimsy(.*?)\.apache\.org/, 'ServerName whimsy.local'
 
 conf.gsub! 'ServerAlias', '## ServerAlias'