The new iCal Server in Leopard server is a great tool, but it isn’t the only way to share calendar data on the Internet. In the days before Leopard Server, the way to share your calendar from iCal was to publish it on .Mac (now MobileMe) or a WebDAV share. Mac OS X Server’s web server is fully capable of hosting WebDAV shares and it is quick and easy to set up.
Before we continue, I want to make sure that this is the way you want to share your calendars on the net.
There are 2 ways to share calendars on Mac OS X Server: iCal Server and WebDAV posting.
iCal Server allows for users to do group calendaring with advanced features such as free/busy resolution, room and equipment reservations and calendar delegation. If more than 1 user needs to have read/write access to a calendar then you want iCal Server. You can use iCal Server with iCal under Leopard as well as several other clients (most are open-source and cross-platform).
WebDAV publishing essentially takes the ics file for a local calendar and makes it available for others to subscribe to in a read/only fashion. With WebDAV publishing you need a web server and users cannot have read/write access to each other’s calendars. You also do not get any of the advanced group calendaring capabilities that iCal Server offers.
For many this is OK and if WebDAV publishing is what you want then read on.
The basic steps necessary to get WebDAV publishing working with iCal and Mac OS X Server are:
- Set up WebDAV on Mac OS X Server
- Configure user access to the WebDAV share
- Configure iCal to publish to WebDAV
- Configure another user’s iCal to subscribe to the calendar
Sounds pretty straightforward, huh?
Disclaimer: Never do test configurations on a production server. Always have an extra server available to test configuration changes on. Always have a backup of your server and be ready to do an immediate restore in the event that Something Bad happens. You take your server’s well-being in your own hands when you change configurations.
This example assumes the server is configured as an Advanced mode server. That means we will be using Server Admin and Workgroup Manager to make changes to server, user and group settings and not using Server Preferences. If your server was set up as a Standard mode server and you are using Server Preferences to configure your server, you can convert your server to Advanced mode by connecting to it with Server Admin. Converting to Advanced mode is one-way and should not result in any data loss or configuration changes.
Always have a backup.
Never change server configs during the working day.
Always test new configs on a test server.
Configuring Mac OS X Server 10.5.4 for WebDAV
In this example I will be using Mac OS X Server 10.5.4. If you are not using Mac OS X Server 10.5.4 your screen may look different and the precise steps may vary.
Step 1: Create a folder for the calendars
Select your server in the pane on the left and choose File Sharing in the toolbar. Choose Volumes and Browse in the top of the volume browser view below the toolbar. Use the volume browser to browse to Library > WebServer > Documents.
Click New Folder and name the folder calendars.
In the Permissions section at the bottom of the window, make _www the owner or group for the folder and give it read/write access.
Step 2: Set up your users & group
Crack open Workgroup Manager and connect to your server as your directory administrator. If your server is an Open Directory master (not necessary for this example) choose LDAPv3/127.0.0.1 from the globe popup under the toolbar. If your server is standalone, you can choose Local from that menu.
Make sure your have Accounts select in the toolbar and click the groups button above the left-hand list view. Click the New Group button in the toolbar. Name your new group calgroup.
Click the Members tab in the right-hand pane and add some users to your group. Click the plus button on the far right and drag users from the pane that opens on the side of the window.
We’re done here so go ahead and quit Workgroup Manager.
Step 3: Configure Web services
Back to Server Admin.
Make sure Web services are visible under your server in the left pane by choosing your server in the left then Settings in the toolbar and finally checking Web under the Settings tab. Now select Web under your server in the left pane.
Click Start Web at the bottom left of the window. Go to Sites in the toolbar and make sure that the enabled checkbox is checked for your site. In this example I have a single site and it is the default site for the server.
The default settings under the General tab will be correct so go to the Options tab and enable WebDAV.
Proceed to the Realms tab and click the plus button at the bottom of the left pane under the Realms tab.
Set the Realm Name to calendars, the Authentication to Digest, and Folder to /Library/WebServer/Documents/calendars.
The default permissions for your new realm (AKA WebDAV share, AKA folder…) is Everyone no access. To protect your calendars from just anyone finding them we’re going to protect them by leaving Everyone with no access.
Click the plus button below the Users & Groups pane, click the Groups tab and drag calgroup to the Users & Groups pane.
Set the calgroup permissions to Browse and Read/Write WebDAV.
Click Save at the bottom right of the Server Admin window and quit Server Admin.
Step 4: Publish a calendar
Launch iCal (this works for both 10.4 and 10.5 versions of iCal, but I am showing 10.5.4) and select a calendar that you want to make available for other users to subscribe to.
Under the Calendar menu choose Publish… Choose a Private Server in the Publish On popup.
In Publish calendar as, enter a descriptive name without any spaces or punctuation.
For Base URL put in the DNS name for your server followed by /calendars
The checkboxes below the Base URL box deserve some explanation.
- Publish changes automatically does pretty much what you would think it does.
- Publish titles and notes allows for a little bit of privacy while still showing others your availability.
If you publish a calendar with this unchecked and see this:
- Publish To Do items, Publish alarms, and Publish attachments work as I suspect you would expect (subject to the subscriber’s settings, more later)
When you click Publish iCal will send a copy of your calendar to the server and offer to send an announcement email for others to subscribe to your calendar. Go ahead and have iCal get your announcement mail ready.
Step 5: Subscribe to your published calendar
In Mail you will see a new message titled “Subscribe to my calendar on the Web”. In there will be a webcal:// URL.
Select and copy the URL to the clipboard then go back to iCal.
Choose Calendar in the menu bar and the Subscribe…
Paste your calendar’s URL into the sheet that pops down and press return. You will be presented with an authentication dialog box. Enter your username and password as requested.
Once iCal verifies the calendar you will be presented with a list of options for your subscription:
I recommend leaving all three options under Remove checked unless you really trust the person whose calendar you are subscribed to. There are potential security issues with not stripping alarms or attachments and you likely don’t care what other people have in their to do lists.
Also, you will probably want to change Auto-refresh to something other than No.
Please take note that it would be possible for one user to overwrite another user’s calendar in the unlikely event that they publish their calendars with the same name. I suggest telling users to publish their calendars with their names as the title in the Publish calendar as box.
As always, your comments are appreciated.