{"id":16900069,"url":"https://github.com/runlevel5/basic_rails_auth_demo","last_synced_at":"2025-03-20T12:25:13.806Z","repository":{"id":15311877,"uuid":"18041796","full_name":"runlevel5/basic_rails_auth_demo","owner":"runlevel5","description":"An example how to properly implement Rails basic auhentication","archived":false,"fork":false,"pushed_at":"2014-04-11T01:13:08.000Z","size":160,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-25T12:28:00.399Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/runlevel5.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-03-23T19:37:29.000Z","updated_at":"2018-09-18T14:12:40.000Z","dependencies_parsed_at":"2022-08-25T20:20:20.945Z","dependency_job_id":null,"html_url":"https://github.com/runlevel5/basic_rails_auth_demo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/runlevel5%2Fbasic_rails_auth_demo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/runlevel5%2Fbasic_rails_auth_demo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/runlevel5%2Fbasic_rails_auth_demo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/runlevel5%2Fbasic_rails_auth_demo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/runlevel5","download_url":"https://codeload.github.com/runlevel5/basic_rails_auth_demo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244610348,"owners_count":20480966,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-13T17:51:27.384Z","updated_at":"2025-03-20T12:25:13.782Z","avatar_url":"https://github.com/runlevel5.png","language":"Ruby","readme":"# Rails Basic Auth demo\n\nDevise or any Warden-based solutions are widely-used but\nunattractive for its complexity.\n\nI am going to show you how to implement a very basic auth\nfor Rails with BCrypt.\n\nPlease be noted that my code does not contain any ActiveRecord\ncallbacks and I also heavily use DCI Service Object pattern.\n\n## Setup\n\n1. Bootstrap DB\n\n```ruby\nrake db:create db:migrate\n```\n\n2. Create new user under `rails console`\n\n```ruby\nUserCreation.create(email: 'your_email', password: 'pass', password_confirmation: 'pass')\n```\n\n3. Run server `rails server`\n\n4. You can test the login\n\n## Testing\n\n```ruby\nRAILS_ENV=tes rake db:schema:load\nbundle exec rake spec\n```\n\n## Author\n\nTrung Lê \u003ctrung_dot_le_at_ruby_dash_journal_dot_com\u003e\n\n## License\n\nMIT\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frunlevel5%2Fbasic_rails_auth_demo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frunlevel5%2Fbasic_rails_auth_demo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frunlevel5%2Fbasic_rails_auth_demo/lists"}