-
Notifications
You must be signed in to change notification settings - Fork 54
Installing PowerDNS on Rails
PowerDNS on Rails is a Ruby on Rails application, and needs the following dependencies satisfied
- Ruby 1.8.6
- Rubygems 1.0 or later
- Rake (or sudo gem install rake)
- git
All the required gems (including Rails) are bundled in the source code for ease of use.
Since it manages a database backend for PowerDNS, you need PowerDNS installed and configured somewhere.
The source is available via Git (recommended), or HTTP download.
$ git clone git://github.com/kennethkalmer/powerdns-on-rails.git
Future updates are a matter of git pull, when inside the project directory.
$ wget http://github.com/kennethkalmer/powerdns-on-rails/tarball/master $ tar -zxf kennethkalmer-powerdns-on-rails-[SHA].tar.gz
The downside to using HTTP is that you can’t use git’s update mechanisms to stay up to date.
We recommend you create a new blank database initially, leaving your original PowerDNS database intact.
Once you’ve got the code, you need to tell PowerDNS on Rails where to find the PowerDNS database. You do this by editing the database.yml file, found in the config/ directory.
Then you need to setup the database structure by running the following command:
$ rake db:schema:load
Then you can add some seed data to the database to get going, run the following command:
$ rake db:seed
Seeding the database gives you some sample zones, templates and an administrator user.
Discuss the import script here
Once you’re done with importing your old data, you can start the application by running the following command:
$ ./script/server
PowerDNS on Rails is then available on port 3000 of the host where you started it. If you seeded the database as instructed, you can login using “admin” and “secret”.
See the Deployment page for instructions on getting PowerDNS on Rails into a production environment. Please help extend the documentation by submitting updates to LightHouse and tagging them with “docs”.