Modernizes the docker instance, and add seeds.rb.

This commit is contained in:
Jonathan Rosenbaum
2017-09-09 02:54:14 +00:00
parent 9f89488f49
commit d540f29354
3 changed files with 46 additions and 4 deletions
+13
View File
@@ -0,0 +1,13 @@
require "bcrypt"
salt = BCrypt::Engine.generate_salt
encrypted_password = BCrypt::Engine.hash_secret('password', salt)
User.create!(:email => "bike@bikelover.org", :encrypted_password => encrypted_pa
ssword).save(validate: false);
Bike.create!(log_number: 1, brand: "Schwinn", model: "Paramount", bike_type: "Ro
ad", color: "Radiant Coppertone", purpose: "Sale", price: 300, serial_number: "2
2bikebike22")
Bike.create!(log_number: 2, brand: "Schwinn", model: "Paramount", bike_type: "
Road", color: "Flamboyant Lime", purpose: "Freecyclery", serial_number: "33bikeb
ike33")