create admin user at first start of server

This commit is contained in:
Vokhmin Alexey V 2013-03-29 16:30:22 +04:00
parent 76e19f717c
commit 574396e03c
1 changed files with 4 additions and 1 deletions

View File

@ -8,3 +8,6 @@ end
user = User.new uname: uname, email: "#{uname}@rosalinux.ru", password: SecureRandom.base64
user.confirmed_at, user.role = Time.now.utc, 'system'; user.save
end
admin = User.new uname: 'admin', email: 'admin@rosalinux.ru', password: 'qwerty'
admin.confirmed_at, admin.role = Time.now.utc, 'admin'; admin.save