3

I have OS X El Capitan and OS X server 5.0.4 installed. Both web and Xcode are enabled. Set web default location contains an index.html

When I open a browser and point to my domain like http://mydomain/ it directs to https://mydomain/xcode/.

How do I change this to make /mydomain/ point to /mydomain/index.html instead of /mydomain/xcode/? I already removed all Xcode stuff in /Library/Server/Web/Config/apache2/sites configuration file but it's not working.

2
  • What steps did you take to "set web default location" - can you detail that or upload the screen image of how you have things set? What browser is connecting to "mydomain" and what OS / network is it using to connect? (connecting from a mobile browser that isn't on your same WiFi often helps rule out DNS issues and other network issues). Also - don't delete things from /Library. Can you restore them from a backup to ensure you didn't break things further?
    – bmike
    Oct 6, 2015 at 17:12
  • set web default location in OS X server web setting. I don't think it is browser issue, all chrome, firefox, safari are the same. I can access /mydomain/index.html directly. However, if I just /mydomain/, it is automatically redirect to mydomain/xcode/ .
    – Jason Lee
    Oct 6, 2015 at 18:23

2 Answers 2

1

This has to do with removing a configuration file, that is used by the server, for wiki and Xcode. All that's in the file is a bit saying YES service is active, you could probably just change that to NO, but deleting the file works for starters. And as long as you don't restart the Xcode service the file won't get recreated!

See this thread: Cannot change default webpage

It appears to be a bug. The short answer is to remove/rename this file:

/Library/Server/Web/Config/apache2/other/COM.APPLE.WEBAPP.WIKI.conf

Note, that you can turn the Wiki service on and then remove/rename this file and the Wiki and Web service will work fine (and with the correct index order). However, turning the Wiki service off and back on will recreate the file and thus cause the issue to reappear. To address that issue I wrote a simple BASH script to check if the file exists and if so, delete it. I then made a LaunchDaemon to run the script every 15 seconds.

and:

But as an added bonus, my problem wasn't wiki, it was Xcode, and the same goes >for removing:

/Library/Server/Web/Config/apache2/other/COM.APPLE.WEBAPP.XCODE.conf

I am thinking about changing the YES to NO in the file tho to see if that keeps >things on lockdown incase of restarts...

0

Here is Apple's response to this issue:

https://support.apple.com/en-ie/HT205290

To summarize, they say to rename or delete the file.

1
  • Welcome to Ask Different. We like answers to be more than just a single line. Ideally, you want to explain why your answer is *right." It also helps to provide links, citations, and/or screen shots. Please review our help section How to Answer on writing good answers to questions
    – Allan
    Aug 31, 2016 at 23:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .