Skip to content

Instantly share code, notes, and snippets.

@pitpit
Last active December 23, 2015 01:19
Show Gist options
  • Save pitpit/6560002 to your computer and use it in GitHub Desktop.
Save pitpit/6560002 to your computer and use it in GitHub Desktop.
```
$ sudo named-checkconf /etc/named.conf
$ sudo named-checkzone local /var/named/local.zone
zone local/IN: loaded serial 45
OK
```
```
sudo launchctl load -w /System/Library/LaunchDaemons/org.isc.named.plist
```
#/etc/apache2/extra/httpd-vhosts.conf
NameVirtualHost *:80
<VirtualHost *:80>
ServerName local
ServerAlias *.local
VirtualDocumentRoot /Users/damien/workspace/%-2+/web
<Directory "/Users/damien/workspace">
AllowOverride all
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
// /var/named/local.zone
$TTL 60
$ORIGIN local.
@ 1D IN SOA localhost. root.localhost. (
45 ; serial (d. adams)
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum
1D IN NS localhost.
1D IN A 127.0.0.1
*.local. 60 IN A 127.0.0.1
//add this at the end of the file /etc/named.conf
zone "local" IN {
type master;
file "appname.zone";
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment