apach2 virtual host

26 views
Skip to first unread message

Jason Hatman

unread,
Feb 21, 2014, 2:51:42 PM2/21/14
to munkise...@googlegroups.com
I know that this is a knowledge problem on my part.  That being said, I've followed the instructions and I have a working munkiserver using "rails s -e production".  I'm now trying to run it in apache.  I've gotten all the way to the end, but when I restart apache2 and load up *munkiserver*.local in a web browser, it only says "It Works".  Why is it showing the default page and not my munkiserver?  Thanks in advance.

Jason

Server: OS X 10.8.5

Riley Shott

unread,
Feb 21, 2014, 3:02:43 PM2/21/14
to munkise...@googlegroups.com
Could you copy & paste your vhost file for munkiserver?

-Riley


--
You received this message because you are subscribed to the Google Groups "munkiserver-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to munkiserver-d...@googlegroups.com.
To post to this group, send email to munkise...@googlegroups.com.
Visit this group at http://groups.google.com/group/munkiserver-dev.
For more options, visit https://groups.google.com/groups/opt_out.

Jason Hatman

unread,
Feb 21, 2014, 3:09:11 PM2/21/14
to munkise...@googlegroups.com
Sure. Here it is.  I just added the new entry the existing /etc/apache2/extra/httpd-vhosts.conf file.

#
# Virtual Hosts
#
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.

#
# Use name-based virtual hosting.
#
NameVirtualHost *:80

#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for all requests that do not
# match a ServerName or ServerAlias in any <VirtualHost> block.
#
<VirtualHost *:80>
    DocumentRoot "/usr/docs/dummy-host.example.com"
    ServerName dummy-host.example.com
    ServerAlias www.dummy-host.example.com
    ErrorLog "/private/var/log/apache2/dummy-host.example.com-error_log"
    CustomLog "/private/var/log/apache2/dummy-host.example.com-access_log" common
</VirtualHost>

<VirtualHost *:80>
    DocumentRoot "/usr/docs/dummy-host2.example.com"
    ServerName dummy-host2.example.com
    ErrorLog "/private/var/log/apache2/dummy-host2.example.com-error_log"
    CustomLog "/private/var/log/apache2/dummy-host2.example.com-access_log" common
</VirtualHost>

<VirtualHost *:80>
  DocumentRoot "/Users/admin/munkiserver/public"
  <Directory "/Users/admin/munkiserver/public">
    Order allow,deny
    Allow from all
  </Directory>
  LoadModule xsendfile_module   /usr/libexec/apache2/mod_xsendfile.so
RequestHeader Set X-Sendfile-Type X-Sendfile
ProxyPassReverse / http://localhost:8001/
XSendFile on
XSendFilePath /Users/admin/munkiserver/packages
</VirtualHost>

Jason Hatman

unread,
Feb 21, 2014, 3:23:58 PM2/21/14
to munkise...@googlegroups.com
Never mind.  I figured out with a help from Google that I needed to uncomment the following line in /etc/apache2/httpd.conf

# Virtual hosts

Include /private/etc/apache2/extra/httpd-vhosts.conf
Reply all
Reply to author
Forward
0 new messages