📜 ⬆️ ⬇️

iDisk do it yourself in 5 minutes

iDisk is essentially WebDav with advanced features from Apple. Therefore, we need Apache + mod_dav + mod_auth_digest.

The following is the configuration for Apache:
<VirtualHost *: 80 >
ServerName your.domain
ServerAlias idisk.mac.com
DocumentRoot / home / idisk / storage /
ErrorLog / var / log / apache2 / idisk-error_log
TransferLog / var / log / apache2 / idisk-access_log
</ Virtualhost>

<Directory "/ home / idisk / storage /" >
Dav on
Authtype digest
AuthName iTools
AuthDigestDomain "/"
AuthUserFile / home / idisk / passwd
Options + Indexes
AllowOverride None
')
< LimitExcept GET HEAD OPTIONS >
require valid-user
</ LimitExcept >

Order allow , deny
Allow from All
</ Directory>


Next, create directories, a password file and restart Apache:
$ mkdir -p / home / idisk / storage / test_user
$ chown apache: apache -R / home / idisk / storage /
$ htdigest -c / home / idisk / passwd iTools test_user
$ /etc/init.d/apache restart


It remains to configure the correct rezolving of the name idisk.mac.com on the IP of our server. To do this, add the following line to the / private / etc / hosts file on your local computer.

YOUR.IP.ADD.RESS idisk.mac.com


Now the matter is left to small - open System Preferences ->. Mac and enter test_user and our password. This is done because when trying to connect to “My iDisk”, the user name cannot be entered and is taken from here (It’s clear that you cannot login to Mac.) :-)

Well, now the final. Open the Finder, select Go-> iDisk-> My iDisk in the menu, enter the password and voila!

In the place of detention I would like to note that this configuration is provided for informational purposes and needs to be improved (for example, the directories on the server can be viewed by all users using a regular browser). Also, the iDisk configuration panel in System Preferences will not be available; it is possible to access those options through various third-party utilities or .plist configuration files. If you want to have the full range of .Mac features, then you can familiarize yourself with the following project - code.google.com/p/dotmac

Source: https://habr.com/ru/post/21621/


All Articles