Use the inet type for IP addresses in postgres.

This commit is contained in:
Tom Hughes 2009-04-09 15:17:12 +00:00
parent 2e1414b229
commit 7fff6361c1
2 changed files with 5 additions and 6 deletions

View file

@ -2,16 +2,13 @@ class CreateAcls < ActiveRecord::Migration
def self.up
create_table "acls", myisam_table do |t|
t.column "id", :integer_pk, :null => false
t.column "address", :integer, :null => false
t.column "netmask", :integer, :null => false
t.column "address", :inet, :null => false
t.column "netmask", :inet, :null => false
t.column "k", :string, :null => false
t.column "v", :string
end
add_index "acls", ["k"], :name => "acls_k_idx"
change_column "acls", "address", :integer, :null => false, :unsigned => true
change_column "acls", "netmask", :integer, :null => false, :unsigned => true
end
def self.down