lobsters / lobsters-ansible

Ansible playbook for lobste.rs
ISC License
79 stars 25 forks source link

Getting vagrant working out of the box. #43

Closed thomasdziedzic closed 3 years ago

thomasdziedzic commented 5 years ago

I cloned this repo for the first time and ran vagrant up on ubuntu 18.04.

I got the following error:

TASK [lobsters : migrate database] *********************************************
Saturday 24 August 2019  18:47:59 -0500 (0:01:46.212)       0:03:19.467 ******* 
fatal: [lobsters.xen.prgmr.com]: FAILED! => {"changed": true, "cmd": ["bundle", "exec", "rails", "db:migrate"], "delta": "0:00:02.318427", "end": "2019-08-24 23:48:01.101530", "msg": "non-zero return code", "rc": 1, "start": "2019-08-24 23:47:58.783103", "stderr": "rails aborted!\nCannot load database configuration:\nCould not load database configuration. No such file - [\"config/database.yml\"]\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application/configuration.rb:185:in `database_configuration'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/railtie.rb:133:in `block (2 levels) in <class:Railtie>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `instance_eval'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `block in execute_hook'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:62:in `with_execution_control'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:67:in `execute_hook'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:52:in `block in run_load_hooks'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `each'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `run_load_hooks'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:328:in `<module:ActiveRecord>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:27:in `<top (required)>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/adapters/postgres.rb:38:in `initialize'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `new'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `initialize'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `new'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `configuration'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:35:in `configure'\n/srv/lobste.rs/http/config/initializers/scenic.rb:1:in `<top (required)>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `block in load'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:657:in `block in load_config_initializer'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/notifications.rb:170:in `instrument'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:656:in `load_config_initializer'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:614:in `block (2 levels) in <class:Engine>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `each'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `block in <class:Engine>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `instance_exec'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `run'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:61:in `block in run_initializers'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `each'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `tsort_each_child'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:60:in `run_initializers'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:361:in `initialize!'\n/srv/lobste.rs/http/config/environment.rb:5:in `<top (required)>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:337:in `require_environment!'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:520:in `block in run_tasks_blocks'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:20:in `perform'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/command.rb:48:in `invoke'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands.rb:18:in `<top (required)>'\nbin/rails:4:in `require'\nbin/rails:4:in `<main>'\n\nCaused by:\nCould not load database configuration. No such file - [\"config/database.yml\"]\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application/configuration.rb:185:in `database_configuration'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/railtie.rb:133:in `block (2 levels) in <class:Railtie>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `instance_eval'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `block in execute_hook'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:62:in `with_execution_control'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:67:in `execute_hook'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:52:in `block in run_load_hooks'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `each'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `run_load_hooks'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:328:in `<module:ActiveRecord>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:27:in `<top (required)>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/adapters/postgres.rb:38:in `initialize'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `new'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `initialize'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `new'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `configuration'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:35:in `configure'\n/srv/lobste.rs/http/config/initializers/scenic.rb:1:in `<top (required)>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `block in load'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:657:in `block in load_config_initializer'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/notifications.rb:170:in `instrument'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:656:in `load_config_initializer'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:614:in `block (2 levels) in <class:Engine>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `each'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `block in <class:Engine>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `instance_exec'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `run'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:61:in `block in run_initializers'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `each'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `tsort_each_child'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:60:in `run_initializers'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:361:in `initialize!'\n/srv/lobste.rs/http/config/environment.rb:5:in `<top (required)>'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:337:in `require_environment!'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:520:in `block in run_tasks_blocks'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:20:in `perform'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/command.rb:48:in `invoke'\n/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands.rb:18:in `<top (required)>'\nbin/rails:4:in `require'\nbin/rails:4:in `<main>'\nTasks: TOP => db:migrate => db:load_config => environment\n(See full trace by running task with --trace)", "stderr_lines": ["rails aborted!", "Cannot load database configuration:", "Could not load database configuration. No such file - [\"config/database.yml\"]", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application/configuration.rb:185:in `database_configuration'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/railtie.rb:133:in `block (2 levels) in <class:Railtie>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `instance_eval'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `block in execute_hook'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:62:in `with_execution_control'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:67:in `execute_hook'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:52:in `block in run_load_hooks'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `each'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `run_load_hooks'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:328:in `<module:ActiveRecord>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:27:in `<top (required)>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/adapters/postgres.rb:38:in `initialize'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `new'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `initialize'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `new'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `configuration'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:35:in `configure'", "/srv/lobste.rs/http/config/initializers/scenic.rb:1:in `<top (required)>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `block in load'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:657:in `block in load_config_initializer'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/notifications.rb:170:in `instrument'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:656:in `load_config_initializer'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:614:in `block (2 levels) in <class:Engine>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `each'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `block in <class:Engine>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `instance_exec'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `run'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:61:in `block in run_initializers'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `each'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `tsort_each_child'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:60:in `run_initializers'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:361:in `initialize!'", "/srv/lobste.rs/http/config/environment.rb:5:in `<top (required)>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:337:in `require_environment!'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:520:in `block in run_tasks_blocks'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:20:in `perform'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/command.rb:48:in `invoke'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands.rb:18:in `<top (required)>'", "bin/rails:4:in `require'", "bin/rails:4:in `<main>'", "", "Caused by:", "Could not load database configuration. No such file - [\"config/database.yml\"]", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application/configuration.rb:185:in `database_configuration'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/railtie.rb:133:in `block (2 levels) in <class:Railtie>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `instance_eval'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:71:in `block in execute_hook'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:62:in `with_execution_control'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:67:in `execute_hook'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:52:in `block in run_load_hooks'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `each'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/lazy_load_hooks.rb:51:in `run_load_hooks'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:328:in `<module:ActiveRecord>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.3/lib/active_record/base.rb:27:in `<top (required)>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/adapters/postgres.rb:38:in `initialize'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `new'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:10:in `initialize'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `new'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:16:in `configuration'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/scenic-1.5.1/lib/scenic/configuration.rb:35:in `configure'", "/srv/lobste.rs/http/config/initializers/scenic.rb:1:in `<top (required)>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `block in load'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:285:in `load'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:657:in `block in load_config_initializer'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/notifications.rb:170:in `instrument'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:656:in `load_config_initializer'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:614:in `block (2 levels) in <class:Engine>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `each'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/engine.rb:613:in `block in <class:Engine>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `instance_exec'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:32:in `run'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:61:in `block in run_initializers'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `each'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:50:in `tsort_each_child'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/initializable.rb:60:in `run_initializers'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:361:in `initialize!'", "/srv/lobste.rs/http/config/environment.rb:5:in `<top (required)>'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:337:in `require_environment!'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/application.rb:520:in `block in run_tasks_blocks'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands/rake/rake_command.rb:20:in `perform'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/command.rb:48:in `invoke'", "/srv/lobste.rs/http/vendor/bundle/ruby/2.3.0/gems/railties-5.2.3/lib/rails/commands.rb:18:in `<top (required)>'", "bin/rails:4:in `require'", "bin/rails:4:in `<main>'", "Tasks: TOP => db:migrate => db:load_config => environment", "(See full trace by running task with --trace)"], "stdout": "", "stdout_lines": []}

It looks like out of the box, it's cloning the lobsters git repo and then running db:migrate without creating a config/database.yml which results in the error.

How am I supposed to set up this repo so that it cleanly runs?

nford commented 5 years ago

You have to create the file yourself. The instruction is in the README of the main lobsters repo https://github.com/lobsters/lobsters/blob/master/README.md

Create a MySQL (other DBs supported by ActiveRecord may work, only MySQL and MariaDB have been tested) database, username, and password and put them in a config/database.yml file.

thomasdziedzic commented 5 years ago

Ah, so a vagrant up is expected to fail during the first pass? I can work with that, but is there any way to set it up so that it automatically sets up a file so that beginner's don't have to worry about expected failures?

I'm used to chef, and I always had it setup so that my tests always passed, even if I had to setup dummy passwords for testing such that the initial run will always work out of the box.

pushcx commented 5 years ago

@jstoja Do you want to chime in on this? I don't think it's been touched much since #10.

jstoja commented 3 years ago

Started to fix it, but hit #68. All in all, the configuration file should probably be templated by Ansible in the future. Since it contains secrets, this kind of information should be stored in ansible-vault (AES256).

pushcx commented 3 years ago

I've removed the Vagrantfile because I don't know how to maintain it. Like with the Docker repo and our Rails app, I'd prefer to link to an external repo.