I'm new to Heroku and I'm trying to update the stack for an app but my attempts to push keep getting rejected. In each case it's telling me that freetds is missing but I've tried following several responses on other posts as well as docs I've been able to find. freetds is installed via homebrew on my machine. I tried Following is the output.
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Ruby app detected
remote: -----> Compiling Ruby/Rails
remote: -----> Using Ruby version: ruby-2.0.0
remote: -----> Installing dependencies using bundler 1.9.7
remote: Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
remote: Fetching gem metadata from https://rubygems.org/...........
remote: Fetching version metadata from https://rubygems.org/...
remote: Fetching dependency metadata from https://rubygems.org/..
remote: Fetching git://github.com/centresource/activerecord-sqlserver-adapter.git
remote: Fetching git://github.com/contextoptional/oauth-ruby.git
remote: Rubygems 2.0.14 is not threadsafe, so your gems must be installed one at a time. Upgrade to Rubygems 2.1.0 or higher to enable parallel gem installation.
remote: Installing rake 10.3.2
remote: Installing i18n 0.6.11
remote: Installing json 1.8.1
remote: Installing minitest 5.4.0
remote: Installing atomic 1.1.14
remote: Installing thread_safe 0.1.3
remote: Installing tzinfo 1.2.1
remote: Installing activesupport 4.1.4
remote: Installing builder 3.2.2
remote: Installing erubis 2.7.0
remote: Installing actionview 4.1.4
remote: Installing rack 1.5.2
remote: Installing rack-test 0.6.2
remote: Installing actionpack 4.1.4
remote: Installing mime-types 1.25.1
remote: Installing polyglot 0.3.5
remote: Installing treetop 1.4.15
remote: Installing mail 2.5.4
remote: Installing actionmailer 4.1.4
remote: Installing activemodel 4.1.4
remote: Installing arel 5.0.1.20140414130214
remote: Installing activerecord 4.1.4
remote: Using activerecord-sqlserver-adapter 4.1.0.pre from git://github.com/centresource/activerecord-sqlserver-adapter.git (at 4.1-stable)
remote: Installing rails-observers 0.1.2
remote: Installing activeresource 4.0.0
remote: Installing bcrypt-ruby 3.1.2
remote: Installing coffee-script-source 1.7.1
remote: Installing execjs 2.0.2
remote: Installing coffee-script 2.3.0
remote: Installing thor 0.19.1
remote: Installing railties 4.1.4
remote: Installing coffee-rails 4.0.1
remote: Installing daemons 1.1.9
remote: Installing multipart-post 1.2.0
remote: Installing databasedotcom 1.3.2
remote: Installing orm_adapter 0.4.0
remote: Installing warden 1.2.3
remote: Installing devise 3.1.1
remote: Installing eventmachine 1.0.8
remote: Installing excon 0.38.0
remote: Installing hike 1.2.3
remote: Installing jquery-rails 3.0.4
remote: Installing kaminari 0.14.1
remote: Installing mailchimp-api 2.0.5
remote: Installing mono_logger 1.1.0
remote: Installing multi_json 1.10.1
remote: Using oauth 0.4.7 from git://github.com/contextoptional/oauth-ruby.git (at master)
remote: Installing pg 0.17.0
remote: Installing rack-protection 1.5.3
remote: Using bundler 1.9.7
remote: Installing tilt 1.4.1
remote: Installing sprockets 2.11.0
remote: Installing sprockets-rails 2.1.3
remote: Installing rails 4.1.4
remote: Installing redis 3.1.0
remote: Installing redis-namespace 1.5.0
remote: Installing sinatra 1.4.5
remote: Installing vegas 0.1.11
remote: Installing resque 1.25.2
remote: Installing xml-simple 1.1.4
remote: Installing salesforce_bulk 1.0.3
remote: Installing sass 3.2.19
remote: Installing sass-rails 4.0.3
remote: Installing thin 1.6.2
remote: Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
remote: /tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/ruby-2.0.0/bin/ruby extconf.rb
remote: checking for iconv_open() in iconv.h... yes
remote: checking for sybfront.h... no
remote: -----
remote: freetds is missing.
remote: -----
remote: *** extconf.rb failed ***
remote: Could not create Makefile due to some reason, probably lack of necessary
remote: libraries and/or headers. Check the mkmf.log file for more details. You may
remote: need configuration options.
remote: Provided configuration options:
remote: --with-opt-dir
remote: --without-opt-dir
remote: --with-opt-include
remote: --without-opt-include=${opt-dir}/include
remote: --with-opt-lib
remote: --without-opt-lib=${opt-dir}/lib
remote: --with-make-prog
remote: --without-make-prog
remote: --srcdir=.
remote: --curdir
remote: --ruby=/tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/ruby-2.0.0/bin/ruby
remote: --enable-lookup
remote: --disable-lookup
remote: --with-iconv-dir
remote: --without-iconv-dir
remote: --with-iconv-include
remote: --without-iconv-include=${iconv-dir}/include
remote: --with-iconv-lib
remote: --without-iconv-lib=${iconv-dir}/
remote: --with-freetds-dir
remote: --without-freetds-dir
remote: --with-freetds-include
remote: --without-freetds-include=${freetds-dir}/include
remote: --with-freetds-lib
remote: --without-freetds-lib=${freetds-dir}/
remote: Gem files will remain installed in /tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/bundle/ruby/2.0.0/gems/tiny_tds-0.6.1 for inspection.
remote: Results logged to /tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/bundle/ruby/2.0.0/gems/tiny_tds-0.6.1/ext/tiny_tds/gem_make.out
remote: An error occurred while installing tiny_tds (0.6.1), and Bundler cannot
remote: continue.
remote: Make sure that `gem install tiny_tds -v '0.6.1'` succeeds before bundling.
remote: Bundler Output: Fetching gem metadata from https://rubygems.org/...........
remote: Fetching version metadata from https://rubygems.org/...
remote: Fetching dependency metadata from https://rubygems.org/..
remote: Fetching git://github.com/centresource/activerecord-sqlserver-adapter.git
remote: Fetching git://github.com/contextoptional/oauth-ruby.git
remote: Rubygems 2.0.14 is not threadsafe, so your gems must be installed one at a time. Upgrade to Rubygems 2.1.0 or higher to enable parallel gem installation.
remote: Installing rake 10.3.2
remote: Installing i18n 0.6.11
remote: Installing json 1.8.1
remote: Installing minitest 5.4.0
remote: Installing atomic 1.1.14
remote: Installing thread_safe 0.1.3
remote: Installing tzinfo 1.2.1
remote: Installing activesupport 4.1.4
remote: Installing builder 3.2.2
remote: Installing erubis 2.7.0
remote: Installing actionview 4.1.4
remote: Installing rack 1.5.2
remote: Installing rack-test 0.6.2
remote: Installing actionpack 4.1.4
remote: Installing mime-types 1.25.1
remote: Installing polyglot 0.3.5
remote: Installing treetop 1.4.15
remote: Installing mail 2.5.4
remote: Installing actionmailer 4.1.4
remote: Installing activemodel 4.1.4
remote: Installing arel 5.0.1.20140414130214
remote: Installing activerecord 4.1.4
remote: Using activerecord-sqlserver-adapter 4.1.0.pre from git://github.com/centresource/activerecord-sqlserver-adapter.git (at 4.1-stable)
remote: Installing rails-observers 0.1.2
remote: Installing activeresource 4.0.0
remote: Installing bcrypt-ruby 3.1.2
remote: Installing coffee-script-source 1.7.1
remote: Installing execjs 2.0.2
remote: Installing coffee-script 2.3.0
remote: Installing thor 0.19.1
remote: Installing railties 4.1.4
remote: Installing coffee-rails 4.0.1
remote: Installing daemons 1.1.9
remote: Installing multipart-post 1.2.0
remote: Installing databasedotcom 1.3.2
remote: Installing orm_adapter 0.4.0
remote: Installing warden 1.2.3
remote: Installing devise 3.1.1
remote: Installing eventmachine 1.0.8
remote: Installing excon 0.38.0
remote: Installing hike 1.2.3
remote: Installing jquery-rails 3.0.4
remote: Installing kaminari 0.14.1
remote: Installing mailchimp-api 2.0.5
remote: Installing mono_logger 1.1.0
remote: Installing multi_json 1.10.1
remote: Using oauth 0.4.7 from git://github.com/contextoptional/oauth-ruby.git (at master)
remote: Installing pg 0.17.0
remote: Installing rack-protection 1.5.3
remote: Using bundler 1.9.7
remote: Installing tilt 1.4.1
remote: Installing sprockets 2.11.0
remote: Installing sprockets-rails 2.1.3
remote: Installing rails 4.1.4
remote: Installing redis 3.1.0
remote: Installing redis-namespace 1.5.0
remote: Installing sinatra 1.4.5
remote: Installing vegas 0.1.11
remote: Installing resque 1.25.2
remote: Installing xml-simple 1.1.4
remote: Installing salesforce_bulk 1.0.3
remote: Installing sass 3.2.19
remote: Installing sass-rails 4.0.3
remote: Installing thin 1.6.2
remote:
remote: Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
remote:
remote: /tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/ruby-2.0.0/bin/ruby extconf.rb
remote: checking for iconv_open() in iconv.h... yes
remote: checking for sybfront.h... no
remote: -----
remote: freetds is missing.
remote: -----
remote: *** extconf.rb failed ***
remote: Could not create Makefile due to some reason, probably lack of necessary
remote: libraries and/or headers. Check the mkmf.log file for more details. You may
remote: need configuration options.
remote:
remote: Provided configuration options:
remote: --with-opt-dir
remote: --without-opt-dir
remote: --with-opt-include
remote: --without-opt-include=${opt-dir}/include
remote: --with-opt-lib
remote: --without-opt-lib=${opt-dir}/lib
remote: --with-make-prog
remote: --without-make-prog
remote: --srcdir=.
remote: --curdir
remote: --ruby=/tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/ruby-2.0.0/bin/ruby
remote: --enable-lookup
remote: --disable-lookup
remote: --with-iconv-dir
remote: --without-iconv-dir
remote: --with-iconv-include
remote: --without-iconv-include=${iconv-dir}/include
remote: --with-iconv-lib
remote: --without-iconv-lib=${iconv-dir}/
remote: --with-freetds-dir
remote: --without-freetds-dir
remote: --with-freetds-include
remote: --without-freetds-include=${freetds-dir}/include
remote: --with-freetds-lib
remote: --without-freetds-lib=${freetds-dir}/
remote:
remote:
remote: Gem files will remain installed in /tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/bundle/ruby/2.0.0/gems/tiny_tds-0.6.1 for inspection.
remote: Results logged to /tmp/build_f5103be1ef5608a727364f54cfa6332a/vendor/bundle/ruby/2.0.0/gems/tiny_tds-0.6.1/ext/tiny_tds/gem_make.out
remote: An error occurred while installing tiny_tds (0.6.1), and Bundler cannot
remote: continue.
remote: Make sure that `gem install tiny_tds -v '0.6.1'` succeeds before bundling.
remote: !
remote: ! Failed to install gems via Bundler.
remote: !
remote:
remote: ! Push rejected, failed to compile Ruby app
Related
I'm trying to push to heroku and its saying Precompiling assets failed. and i've added config.assets.initialize_on_precompile = false
in the config/application.rb file and i ran a migration i'm not sure what to do
remote: -----> Ruby app detected
remote: -----> Compiling Ruby/Rails
remote: -----> Using Ruby version: ruby-2.5.3
remote: -----> Installing dependencies using bundler 2.0.2
remote: Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
remote: The dependency tzinfo-data (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for x86-mingw32, x86-mswin32, x64-mingw32, java. To add those platforms to the bundle, run `bundle lock --add-platform x86-mingw32 x86-mswin32 x64-mingw32 java`.
remote: Fetching gem metadata from https://rails-assets.org/...
remote: Fetching gem metadata from https://rubygems.org/............
remote: Fetching gem metadata from https://rails-assets.org/...
remote: Using rake 12.3.3
remote: Using concurrent-ruby 1.1.5
remote: Using minitest 5.11.3
remote: Using thread_safe 0.3.6
remote: Using builder 3.2.3
remote: Using erubi 1.8.0
remote: Using mini_portile2 2.4.0
remote: Using crass 1.0.4
remote: Using rack 2.0.7
remote: Using nio4r 2.4.0
remote: Using websocket-extensions 0.1.4
remote: Using mini_mime 1.0.2
remote: Using arel 9.0.0
remote: Using mimemagic 0.3.3
remote: Using execjs 2.7.0
remote: Using msgpack 1.3.1
remote: Using rb-fsevent 0.10.3
remote: Using ffi 1.11.1
remote: Using bundler 2.0.2
remote: Using coffee-script-source 1.12.2
remote: Using method_source 0.9.2
remote: Using thor 0.20.3
remote: Using pg 1.1.4
remote: Using popper_js 1.11.1
remote: Using puma 3.12.1
remote: Using rails-assets-tether 1.4.7
remote: Using tilt 2.0.9
remote: Using turbolinks-source 5.2.0
remote: Using i18n 1.6.0
remote: Using tzinfo 1.2.5
remote: Using nokogiri 1.10.4
remote: Using websocket-driver 0.7.1
remote: Using rack-test 1.1.0
remote: Using mail 2.7.1
remote: Using sprockets 3.7.2
remote: Using marcel 0.3.3
remote: Using bootsnap 1.4.4
remote: Using rb-inotify 0.10.0
remote: Using autoprefixer-rails 9.6.1
remote: Using uglifier 4.1.20
remote: Using coffee-script 2.4.1
remote: Using turbolinks 5.2.0
remote: Using loofah 2.2.3
remote: Using activesupport 5.2.3
remote: Using sass-listen 4.0.0
remote: Using rails-dom-testing 2.0.3
remote: Using rails-html-sanitizer 1.2.0
remote: Using globalid 0.4.2
remote: Using activemodel 5.2.3
remote: Using sass 3.7.4
remote: Using jbuilder 2.9.1
remote: Using actionview 5.2.3
remote: Using activejob 5.2.3
remote: Using activerecord 5.2.3
remote: Using actionpack 5.2.3
remote: Using bootstrap 4.0.0.alpha6
remote: Using actioncable 5.2.3
remote: Using actionmailer 5.2.3
remote: Using activestorage 5.2.3
remote: Using railties 5.2.3
remote: Using sprockets-rails 3.2.1
remote: Fetching simple_form 4.1.0
remote: Using coffee-rails 4.2.2
remote: Using jquery-rails 4.3.5
remote: Using sass-rails 5.0.7
remote: Using rails 5.2.3
remote: Installing simple_form 4.1.0
remote: Bundle complete! 23 Gemfile dependencies, 66 gems now installed.
remote: Gems in the groups development and test were not installed.
remote: Bundled gems are installed into `./vendor/bundle`
remote: Bundle completed (5.10s)
remote: Cleaning up the bundler cache.
remote: -----> Installing node-v10.15.3-linux-x64
remote: -----> Detecting rake tasks
remote: -----> Preparing app for Rails asset pipeline
remote: Running: rake assets:precompile
remote: Yarn executable was not detected in the system.
remote: Download Yarn at https://yarnpkg.com/en/docs/install
remote: rake aborted!
remote: Uglifier::Error: Unexpected line terminator
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/uglifier-4.1.20/lib/uglifier.rb:234:in `parse_result'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/uglifier-4.1.20/lib/uglifier.rb:216:in `run_uglifyjs'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/uglifier-4.1.20/lib/uglifier.rb:168:in `compile'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/uglifier_compressor.rb:53:in `call'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/uglifier_compressor.rb:28:in `call'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:75:in `call_processor'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:57:in `block in call_processors'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:56:in `reverse_each'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:56:in `call_processors'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/loader.rb:134:in `load_from_unloaded'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/loader.rb:60:in `block in load'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/loader.rb:317:in `fetch_asset_from_dependency_cache'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/loader.rb:44:in `load'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/cached_environment.rb:20:in `block in initialize'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/cached_environment.rb:47:in `load'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/base.rb:66:in `find_asset'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/base.rb:73:in `find_all_linked_assets'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/manifest.rb:142:in `block in find'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/legacy.rb:114:in `block (2 levels) in logical_paths'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/path_utils.rb:228:in `block in stat_tree'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/path_utils.rb:212:in `block in stat_directory'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/path_utils.rb:209:in `each'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/path_utils.rb:209:in `stat_directory'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/path_utils.rb:227:in `stat_tree'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/legacy.rb:105:in `each'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/legacy.rb:105:in `block in logical_paths'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/legacy.rb:104:in `each'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/legacy.rb:104:in `logical_paths'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/manifest.rb:140:in `find'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/sprockets/manifest.rb:186:in `compile'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-rails-3.2.1/lib/sprockets/rails/task.rb:68:in `block (3 levels) in define'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-3.7.2/lib/rake/sprocketstask.rb:147:in `with_logger'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/sprockets-rails-3.2.1/lib/sprockets/rails/task.rb:67:in `block (2 levels) in define'
remote: /tmp/build_a5c613e73cd75dee9abde115bd1676ff/vendor/bundle/ruby/2.5.0/gems/rake-12.3.3/exe/rake:27:in `<top (required)>'
remote: Tasks: TOP => assets:precompile
remote: (See full trace by running task with --trace)
remote:
remote: !
remote: ! Precompiling assets failed.
remote: !
remote: ! Push rejected, failed to compile Ruby app.
I'm not sure where its tracing to but i dont think yarn has anything to do with it does it?
I am trying to install a ruby script in heroku. I run bundle install, rake db:create, rake db:migrate when I tried to deploy it to heroku it throws an error,
Here is the Error :
Counting objects: 858, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (366/366), done.
Writing objects: 100% (858/858), 1.27 MiB | 158.00 KiB/s, done.
Total 858 (delta 434), reused 858 (delta 434)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Ruby app detected
remote: -----> Compiling Ruby/Rails
remote: -----> Using Ruby version: ruby-2.3.4
remote: ###### WARNING:
remote: Removing `Gemfile.lock` because it was generated on Windows.
remote: Bundler will do a full resolve so native gems are handled properly.
remote: This may result in unexpected gem versions being used in your app.
remote: In rare occasions Bundler may not be able to resolve your dependencies at all.
remote: https://devcenter.heroku.com/articles/bundler-windows-gemfile
remote:
remote: -----> Installing dependencies using bundler 1.15.2
remote: Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4
remote: The dependency tzinfo-data (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for x86-mingw32, x86-mswin32, x64-mingw32, java. To add those platforms to the bundle, run `bundle lock --add-platform x86-mingw32 x86-mswin32 x64-mingw32 java`.
remote: Fetching gem metadata from https://rubygems.org/..........
remote: Fetching version metadata from https://rubygems.org/..
remote: Fetching dependency metadata from https://rubygems.org/.
remote: Resolving dependencies...
remote: Fetching rake 12.3.0
remote: Fetching concurrent-ruby 1.0.5
remote: Fetching minitest 5.11.3
remote: Installing rake 12.3.0
remote: Installing minitest 5.11.3
remote: Installing concurrent-ruby 1.0.5
remote: Fetching thread_safe 0.3.6
remote: Fetching builder 3.2.3
remote: Installing thread_safe 0.3.6
remote: Installing builder 3.2.3
remote: Fetching erubis 2.7.0
remote: Fetching mini_portile2 2.3.0
remote: Fetching crass 1.0.3
remote: Installing erubis 2.7.0
remote: Installing mini_portile2 2.3.0
remote: Installing crass 1.0.3
remote: Fetching rack 2.0.4
remote: Fetching nio4r 2.2.0
remote: Installing rack 2.0.4
remote: Installing nio4r 2.2.0 with native extensions
remote: Fetching websocket-extensions 0.1.3
remote: Fetching mini_mime 1.0.0
remote: Installing websocket-extensions 0.1.3
remote: Fetching coffee-script-source 1.12.2
remote: Installing mini_mime 1.0.0
remote: Installing coffee-script-source 1.12.2
remote: Fetching execjs 2.7.0
remote: Installing execjs 2.7.0
remote: Fetching method_source 0.9.0
remote: Fetching thor 0.20.0
remote: Installing thor 0.20.0
remote: Installing method_source 0.9.0
remote: Fetching formtastic_i18n 0.6.0
remote: Installing formtastic_i18n 0.6.0
remote: Fetching kaminari-core 1.1.1
remote: Fetching arel 7.1.4
remote: Installing kaminari-core 1.1.1
remote: Installing arel 7.1.4
remote: Fetching rb-fsevent 0.10.2
remote: Fetching ffi 1.9.21
remote: Installing rb-fsevent 0.10.2
remote: Fetching bcrypt 3.1.11
remote: Installing bcrypt 3.1.11 with native extensions
remote: Installing ffi 1.9.21 with native extensions
remote: Using bundler 1.15.2
remote: Fetching orm_adapter 0.5.0
remote: Installing orm_adapter 0.5.0
remote: Fetching multi_json 1.13.1
remote: Installing multi_json 1.13.1
remote: Fetching nested_scaffold 1.0.0
remote: Installing nested_scaffold 1.0.0
remote: Fetching pg 1.0.0
remote: Installing pg 1.0.0 with native extensions
remote: Fetching puma 3.11.2
remote: Installing puma 3.11.2 with native extensions
remote: Fetching tilt 2.0.8
remote: Installing tilt 2.0.8
remote: Fetching turbolinks-source 5.1.0
remote: Installing turbolinks-source 5.1.0
remote: Fetching will_paginate 3.1.6
remote: Installing will_paginate 3.1.6
remote: Fetching i18n 0.9.5
remote: Installing i18n 0.9.5
remote: Fetching tzinfo 1.2.5
remote: Installing tzinfo 1.2.5
remote: Fetching nokogiri 1.8.2
remote: Installing nokogiri 1.8.2 with native extensions
remote: Fetching rack-test 0.6.3
remote: Installing rack-test 0.6.3
remote: Fetching sprockets 3.7.1
remote: Installing sprockets 3.7.1
remote: Fetching warden 1.2.7
remote: Installing warden 1.2.7
remote: Fetching websocket-driver 0.6.5
remote: Installing websocket-driver 0.6.5 with native extensions
remote: Fetching mail 2.7.0
remote: Installing mail 2.7.0
remote: Fetching coffee-script 2.4.1
remote: Installing coffee-script 2.4.1
remote: Fetching autoprefixer-rails 8.0.0
remote: Installing autoprefixer-rails 8.0.0
remote: Fetching uglifier 4.1.6
remote: Installing uglifier 4.1.6
remote: Fetching rb-inotify 0.9.10
remote: Installing rb-inotify 0.9.10
remote: Fetching turbolinks 5.1.0
remote: Installing turbolinks 5.1.0
remote: Fetching activesupport 5.0.6
remote: Installing activesupport 5.0.6
remote: Fetching sass-listen 4.0.0
remote: Installing sass-listen 4.0.0
remote: Fetching globalid 0.4.1
remote: Installing globalid 0.4.1
remote: Fetching arbre 1.1.1
remote: Installing arbre 1.1.1
remote: Fetching activemodel 5.0.6
remote: Installing activemodel 5.0.6
remote: Fetching jbuilder 2.7.0
remote: Installing jbuilder 2.7.0
remote: Fetching sass 3.5.5
remote: Installing sass 3.5.5
remote: Fetching activejob 5.0.6
remote: Installing activejob 5.0.6
remote: Fetching activerecord 5.0.6
remote: Installing activerecord 5.0.6
remote: Fetching bootstrap-sass 3.3.7
remote: Installing bootstrap-sass 3.3.7
remote: Fetching kaminari-activerecord 1.1.1
remote: Installing kaminari-activerecord 1.1.1
remote: Fetching polyamorous 1.3.3
remote: Installing polyamorous 1.3.3
remote: Fetching rails-dom-testing 2.0.3
remote: Fetching loofah 2.2.0
remote: Installing rails-dom-testing 2.0.3
remote: Installing loofah 2.2.0
remote: Fetching rails-html-sanitizer 1.0.3
remote: Installing rails-html-sanitizer 1.0.3
remote: Fetching actionview 5.0.6
remote: Installing actionview 5.0.6
remote: Fetching kaminari-actionview 1.1.1
remote: Fetching actionpack 5.0.6
remote: Installing kaminari-actionview 1.1.1
remote: Fetching kaminari 1.1.1
remote: Installing actionpack 5.0.6
remote: Installing kaminari 1.1.1
remote: Fetching actioncable 5.0.6
remote: Fetching actionmailer 5.0.6
remote: Fetching railties 5.0.6
remote: Installing actionmailer 5.0.6
remote: Installing actioncable 5.0.6
remote: Fetching formtastic 3.1.5
remote: Installing railties 5.0.6
remote: Fetching has_scope 0.7.1
remote: Installing formtastic 3.1.5
remote: Installing has_scope 0.7.1
remote: Fetching ransack 1.8.7
remote: Installing ransack 1.8.7
remote: Fetching sprockets-rails 3.2.1
remote: Installing sprockets-rails 3.2.1
remote: Fetching simple_form 3.5.1
remote: Installing simple_form 3.5.1
remote: Fetching coffee-rails 4.2.2
remote: Fetching responders 2.4.0
remote: Installing coffee-rails 4.2.2
remote: Installing responders 2.4.0
remote: Fetching jquery-rails 4.3.1
remote: Fetching rails 5.0.6
remote: Installing rails 5.0.6
remote: Fetching sass-rails 5.0.7
remote: Installing sass-rails 5.0.7
remote: Fetching inherited_resources 1.8.0
remote: Fetching devise 4.4.1
remote: Installing inherited_resources 1.8.0
remote: Installing jquery-rails 4.3.1
remote: Installing devise 4.4.1
remote: Fetching activeadmin 1.2.1
remote: Installing activeadmin 1.2.1
remote: Bundle complete! 18 Gemfile dependencies, 79 gems now installed.
remote: Gems in the groups development and test were not installed.
remote: Bundled gems are installed into ./vendor/bundle.
remote: Bundle completed (30.42s)
remote: Cleaning up the bundler cache.
remote: -----> Installing node-v6.11.1-linux-x64
remote: -----> Detecting rake tasks
remote: -----> Preparing app for Rails asset pipeline
remote: Running: rake assets:precompile
remote: DEPRECATION WARNING: `config.static_cache_control` is deprecated and will be removed in Rails 5.1.
remote: Please use
remote: `config.public_file_server.headers = { 'Cache-Control' => 'public, max-age=2592000' }`
remote: instead.
remote: (called from block in <top (required)> at /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/config/environments/production.rb:28)
remote: intializing git
remote: rake aborted!
remote: Gem::LoadError: Specified 'postgresql' for database adapter, but the gem is not loaded. Add `gem 'pg'` to your Gemfile (and ensure its version is at the minimum required by ActiveRecord).
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activerecord-5.0.6/lib/active_record/connection_adapters/connection_specification.rb:176:in `rescue in spec'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activerecord-5.0.6/lib/active_record/connection_adapters/connection_specification.rb:173:in `spec'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activerecord-5.0.6/lib/active_record/connection_handling.rb:53:in `establish_connection'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activerecord-5.0.6/lib/active_record/railtie.rb:125:in `block (2 levels) in <class:Railtie>'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:69:in `instance_eval'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:69:in `block in execute_hook'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:60:in `with_execution_control'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:65:in `execute_hook'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:50:in `block in run_load_hooks'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:49:in `each'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/lazy_load_hooks.rb:49:in `run_load_hooks'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/devise-4.4.1/lib/devise/mapping.rb:78:in `modules'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/devise-4.4.1/lib/devise/mapping.rb:95:in `routes'
remote:
/tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/railties-5.0.6/lib/rails/initializable.rb:55:in `block in run_initializers'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/railties-5.0.6/lib/rails/initializable.rb:54:in `run_initializers'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/railties-5.0.6/lib/rails/application.rb:352:in `initialize!'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/config/environment.rb:5:in `<top (required)>'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/dependencies.rb:293:in `require'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/dependencies.rb:293:in `block in require'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/dependencies.rb:259:in `load_dependency'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.6/lib/active_support/dependencies.rb:293:in `require'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/railties-5.0.6/lib/rails/application.rb:328:in `require_environment!'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/railties-5.0.6/lib/rails/application.rb:448:in `block in run_tasks_blocks'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/sprockets-rails-3.2.1/lib/sprockets/rails/task.rb:62:in `block (2 levels) in define'
remote: /tmp/build_95d492fa8732a678c298a47e2e3bb8e4/vendor/bundle/ruby/2.3.0/gems/rake-12.3.0/exe/rake:27:in `<top (required)>'
remote: Tasks: TOP => environment
remote: (See full trace by running task with --trace)
remote: !
remote: ! Precompiling assets failed.
remote: !
remote: ! Push rejected, failed to compile Ruby app.
remote:
remote: ! Push failed
remote: Verifying deploy...
remote:
remote: ! Push rejected to limitless-hamlet-95451.
remote:
To https://git.heroku.com/limitless-hamlet-95451.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/limitless-hamlet-95451.git
'
In localhost it runs smooth..
When you create a rails 5 application with
rails new app-name -d postgresql
it will set postgres gem (pg) to 0.21 by default.
Possibly you've skipped this step when you started your project, and added pg on later stages. Let's rewind.
rails new without-db #defaults to sqlite3
cd without-db
Then I've edited my Gemfile replacing
gem 'sqlite3'
to
gem 'pg'
then
bundle install
Now, postgres gem version is 1.0.0. Edited my database.yml for connection credentials.Then some stuff to generate model, migration, controller etc. and push them to heroku.
$ rails g scaffold book title:string author:string genre:string description:string
...
$ rake db:create
...
$ rake db:migrate
...
$ heroku login
...
$ git init
...
$ heroku git:remote -a without-db-sample
...
$ git add .
...
$ git commit -m "initial commit"
...
$ git push heroku master
...
$ heroku run rake db:migrate
...
$ heroku open
Albeit I don't love this version of pg, it worked normally.
Then edited Gemfile again, replacing,
gem 'pg'
to
gem 'pg', '~> 0.18'
then
$ bundle install
...
$ bundle show pg
/home/ziya/.rvm/gems/ruby-2.4.1/gems/pg-0.21.0
$ git status
...
$ git add .
...
$ git commit -m "change postgres version"
...
$ git push heroku master
It still works normally - https://without-db-sample.herokuapp.com/books
https://github.com/rails/rails/issues/31673
It seems this is a rails issue. I would try specifying a pg gem version in your gem file with gem "pg", "0.21.1"
This is my first post on this topic so please be gentle, but I'm getting a Keyerror when running my app rakefile. Any ideas?
MacBook-Pro:proleaderboard aidenhowes$ git push heroku master
Counting objects: 757, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (293/293), done.
Writing objects: 100% (757/757), 334.41 KiB | 0 bytes/s, done.
Total 757 (delta 419), reused 739 (delta 409)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Ruby app detected
remote: -----> Compiling Ruby/Rails
remote: -----> Using Ruby version: ruby-2.2.4
remote: -----> Installing dependencies using bundler 1.11.2
remote: Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
remote: Warning: the running version of Bundler is older than the version that created the lockfile. We suggest you upgrade to the latest version of Bundler by running `gem install bundler`.
remote: Fetching source index from https://rubygems.org/
remote: Fetching source index from https://rails-assets.org/
remote: Fetching git://github.com/thoughtbot/paperclip.git
remote: Fetching gem metadata from https://rails-assets.org/...
remote: Fetching version metadata from https://rails-assets.org/..
remote: Fetching git://github.com/mislav/will_paginate.git
remote: Fetching git://github.com/bootstrap-ruby/will_paginate- bootstrap.git
remote: Installing rake 11.1.2
remote: Installing concurrent-ruby 1.0.2
remote: Installing i18n 0.7.0
remote: Installing minitest 5.8.4
remote: Installing thread_safe 0.3.5
remote: Installing builder 3.2.2
remote: Installing erubis 2.7.0
remote: Installing mini_portile2 2.0.0
remote: Installing json 1.8.3 with native extensions
remote: Installing nio4r 1.2.1 with native extensions
remote: Installing websocket-extensions 0.1.2
remote: Installing mime-types-data 3.2016.0221
remote: Installing arel 7.0.0
remote: Installing execjs 2.6.0
remote: Installing json_pure 1.8.3
remote: Installing bcrypt 3.1.11 with native extensions
remote: Installing sass 3.4.22
remote: Installing callsite 0.0.11
remote: Installing chartkick 1.5.2
remote: Installing coffee-script-source 1.10.0
remote: Installing method_source 0.8.2
remote: Installing thor 0.19.1
remote: Installing orm_adapter 0.5.0
remote: Installing multi_xml 0.5.5
remote: Installing multi_json 1.12.0
remote: Installing turbolinks-source 5.0.0.beta4
remote: Installing mimemagic 0.3.1
remote: Using bundler 1.11.2
remote: Installing puma 3.4.0 with native extensions
remote: Installing rails-assets-tether 1.3.2
remote: Installing pg 0.18.4 with native extensions
remote: Installing rails_serve_static_assets 0.0.5
remote: Installing rails_stdout_logging 0.0.5
remote: Using will_paginate 3.1.0 from git://github.com/mislav/will_paginate.git (at master#5d92ee2)
remote: Installing tilt 2.0.2
remote: Installing yard 0.8.7.6
remote: Installing faker 1.6.3
remote: Installing tzinfo 1.2.2
remote: Installing nokogiri 1.6.7.2 with native extensions
remote: Installing websocket-driver 0.6.3 with native extensions
remote: Installing mime-types 3.0
remote: Installing autoprefixer-rails 6.3.6
remote: Installing uglifier 3.0.0
remote: Installing jmespath 1.2.4
remote: Installing coffee-script 2.4.1
remote: Installing rack 2.0.0.rc1
remote: Installing httparty 0.13.7
remote: Installing turbolinks 5.0.0.beta2
remote: Installing rails_12factor 0.0.3
remote: Installing activesupport 5.0.0.rc1
remote: Using will_paginate-bootstrap 1.0.1 from git://github.com/bootstrap-ruby/will_paginate-bootstrap.git (at master#5fb4867)
remote: Installing bootstrap 4.0.0.alpha3
remote: Installing mail 2.6.4
remote: Installing aws-sdk-core 2.3.4
remote: Installing warden 1.2.6
remote: Installing rack-test 0.6.3
remote: Installing rack-contrib 1.2.0
remote: Installing rails-deprecated_sanitizer 1.0.3
remote: Installing sprockets 3.6.0
remote: Installing globalid 0.3.6
remote: Installing activemodel 5.0.0.rc1
remote: Installing climate_control 0.0.3
remote: Installing groupdate 2.5.3
remote: Installing jbuilder 2.4.1
remote: Installing loofah 2.0.3
remote: Installing aws-sdk-resources 2.3.4
remote: Installing rails-dom-testing 1.0.7
remote: Installing activejob 5.0.0.rc1
remote: Installing activerecord 5.0.0.rc1
remote: Installing cocaine 0.5.8
remote: Using paperclip 5.0.0.beta2 from git://github.com/thoughtbot/paperclip.git (at master#2c59f96)
remote: Installing rails-html-sanitizer 1.0.3
remote: Installing aws-sdk 2.3.4
remote: Installing actionview 5.0.0.rc1
remote: Installing actionpack 5.0.0.rc1
remote: Installing actionmailer 5.0.0.rc1
remote: Installing actioncable 5.0.0.rc1
remote: Installing railties 5.0.0.rc1
remote: Installing sprockets-rails 3.0.4
remote: Installing responders 2.2.0
remote: Installing coffee-rails 4.1.1
remote: Installing font-awesome-rails 4.6.2.0
remote: Installing jquery-turbolinks 2.1.0
remote: Installing jquery-rails 4.1.1
remote: Installing meta_request 0.4.0
remote: Installing jquery-ui-rails 5.0.5
remote: Installing rails 5.0.0.rc1
remote: Installing sass-rails 5.0.4
remote: Installing devise 4.0.2
remote: Bundle complete! 38 Gemfile dependencies, 89 gems now installed.
remote: Gems in the groups development and test were not installed.
remote: Bundled gems are installed into ./vendor/bundle.
remote: Post-install message from httparty:
remote: When you HTTParty, you must party hard!
remote: Post-install message from paperclip:
remote: ##################################################
remote: # NOTE FOR UPGRADING FROM 4.3.0 OR EARLIER #
remote: ##################################################
remote: Paperclip is now compatible with aws-sdk >= 2.0.0.
remote: If you are using S3 storage, aws-sdk >= 2.0.0 requires you to make a few small
remote: changes:
remote: * You must set the `s3_region`
remote: * If you are explicitly setting permissions anywhere, such as in an initializer,
remote: note that the format of the permissions changed from using an underscore to
remote: using a hyphen. For example, `:public_read` needs to be changed to
remote: `public-read`.
remote: For a walkthrough of upgrading from 4 to 5 and aws-sdk >= 2.0 you can watch
remote: http://rubythursday.com/episodes/ruby-snack-27-upgrade-paperclip-and-aws-sdk-in-prep-for-rails-5
remote: Bundle completed (54.79s)
remote: Cleaning up the bundler cache.
remote: -----> Preparing app for Rails asset pipeline
remote: Running: rake assets:precompile
remote: rake aborted!
remote: KeyError: key not found: "S3_BUCKET_NAME"
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/config/environments/production.rb:92:in `fetch'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/config/environments/production.rb:92:in `block in <top (required)>'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/railtie.rb:209:in `instance_eval'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/railtie.rb:209:in `configure'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/config/environments/production.rb:1:in `<top (required)>'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:293:in `require'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:293:in `block in require'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:259:in `load_dependency'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:293:in `require'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/engine.rb:600:in `block (2 levels) in <class:Engine>'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/engine.rb:599:in `each'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/engine.rb:599:in `block in <class:Engine>'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/initializable.rb:30:in `instance_exec'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/initializable.rb:30:in `run'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/initializable.rb:55:in `block in run_initializers'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/initializable.rb:44:in `each'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/initializable.rb:44:in `tsort_each_child'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/initializable.rb:54:in `run_initializers'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/application.rb:352:in `initialize!'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/config/environment.rb:5:in `<top (required)>'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:293:in `require'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:293:in `block in require'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:259:in `load_dependency'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/activesupport-5.0.0.rc1/lib/active_support/dependencies.rb:293:in `require'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/application.rb:328:in `require_environment!'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/railties-5.0.0.rc1/lib/rails/application.rb:448:in `block in run_tasks_blocks'
remote: /tmp/build_ede61efdc5705c0b3b467412e52dba8a/vendor/bundle/ruby/2.2.0/gems/sprockets-rails-3.0.4/lib/sprockets/rails/task.rb:62:in `block (2 levels) in define'
remote: Tasks: TOP => environment
remote: (See full trace by running task with --trace)
remote: !
remote: ! Precompiling assets failed.
remote: !
remote:
remote: ! Push rejected, failed to compile Ruby app
remote:
remote: Verifying deploy....
remote:
remote: ! Push rejected to proleaderboard.
remote:
To https://git.heroku.com/proleaderboard.git
! [remote rejected] master -> master (pre-receive hook declined)
You need to set S3_BUCKET_NAME environment variable on Heroku.
On CUI you can heroku config:set S3_BUCKET_NAME=name_of_bucket
On GUI you can go to your Heroku app's Settings tab, and Reveal Config Vars and save whatever variables you need.
I recommend setting variables on CUI, because I had an issue that some variables are somehow not loaded, and re-setting of variable on CUI solved problem.
Using Dokku 0.5.3, I have an issue deploying a Ruby/Rack app: Bundler doesn't install my gems in :production group.
Here's my Gemfile:
source 'https://rubygems.org'
ruby '2.3.0'
gem 'bundler'
gem 'sinatra'
gem 'sinatra-contrib'
gem 'json'
gem 'thin'
gem 'instagram'
gem 'data_mapper'
gem 'dm-types',
:git => 'git://github.com/julienma/dm-types.git',
:branch => 'gem-v1.2.2-with-frozen-nilclass-fix'
gem 'dm-postgres-adapter', :group => :production
group :development, :test do
gem 'dm-sqlite-adapter'
gem 'dotenv'
gem 'pry'
end
Here's the output when I push my repo to dokku:
Counting objects: 114, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (91/91), done.
Writing objects: 100% (114/114), 13.76 KiB | 0 bytes/s, done.
Total 114 (delta 53), reused 0 (delta 0)
-----> Cleaning up...
-----> Building my-app from herokuish...
-----> Adding BUILD_ENV to build environment...
-----> Ruby app detected
-----> Compiling Ruby/Rack
-----> Using Ruby version: ruby-2.3.0
-----> Installing dependencies using bundler 1.11.2
Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
Fetching gem metadata from https://rubygems.org/.........
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Fetching git://github.com/julienma/dm-types.git
Installing bcrypt 3.1.11 with native extensions
Installing backports 3.6.8
Installing addressable 2.4.0
Installing daemons 1.2.3
Using json 1.8.3
Installing fastercsv 1.5.5
Installing json_pure 1.8.3
Installing multi_json 1.11.2
Installing stringex 1.5.1
Installing uuidtools 2.1.5
Installing multipart-post 2.0.0
Installing eventmachine 1.2.0.1 with native extensions
Installing hashie 3.4.3
Installing rack 1.6.4
Installing tilt 2.0.2
Using bundler 1.11.2
Installing bcrypt-ruby 3.1.5
Installing dm-core 1.2.1
Installing faraday 0.9.2
Installing rack-protection 1.5.3
Installing rack-test 0.6.3
Installing faraday_middleware 0.9.2
Installing dm-aggregates 1.2.0
Installing dm-constraints 1.2.0
Installing dm-migrations 1.2.0
Installing dm-serializer 1.2.2
Installing dm-transactions 1.2.0
Using dm-types 1.2.2 from git://github.com/julienma/dm-types.git (at gem-v1.2.2-with-frozen-nilclass-fix#b34937c)
Installing dm-timestamps 1.2.0
Installing dm-validations 1.2.0
Installing sinatra 1.4.7
Installing instagram 1.1.6
Installing sinatra-contrib 1.4.6
Installing data_mapper 1.2.0
Installing thin 1.6.4 with native extensions
Bundle complete! 12 Gemfile dependencies, 35 gems now installed.
Gems in the groups development, test and production were not installed.
Bundled gems are installed into ./vendor/bundle.
Bundle completed (42.90s)
Cleaning up the bundler cache.
---
addons: []
config_vars:
LANG: en_US.UTF-8
RACK_ENV: production
default_process_types:
rake: bundle exec rake
console: bundle exec irb
web: bundle exec thin start -R config.ru -e $RACK_ENV -p $PORT
-----> Discovering process types
Procfile declares types -> web
-----> Releasing my-app (dokku/my-app:latest)...
-----> Deploying my-app (dokku/my-app:latest)...
-----> Attempting to run scripts.dokku.predeploy from app.json (if defined)
-----> App Procfile file found (/home/dokku/my-app/DOKKU_PROCFILE)
-----> DOKKU_SCALE file not found in app image. Generating one based on Procfile...
-----> New DOKKU_SCALE file generated
=====> web=1
-----> Running pre-flight checks
For more efficient zero downtime deployments, create a file CHECKS.
See http://dokku.viewdocs.io/dokku/checks-examples.md for examples
CHECKS file not found in container: Running simple container check...
-----> Waiting for 10 seconds ...
remote: App container failed to start!!
=====> my-app web container output:
/app/vendor/bundle/ruby/2.3.0/gems/backports-3.6.8/lib/backports/std_lib.rb:9:in `require': cannot load such file -- dm-postgres-adapter (LoadError)
from /app/vendor/bundle/ruby/2.3.0/gems/backports-3.6.8/lib/backports/std_lib.rb:9:in `require_with_backports'
from /app/vendor/bundle/ruby/2.3.0/gems/dm-core-1.2.1/lib/dm-core/adapters.rb:163:in `load_adapter'
from /app/vendor/bundle/ruby/2.3.0/gems/dm-core-1.2.1/lib/dm-core/adapters.rb:133:in `adapter_class'
from /app/vendor/bundle/ruby/2.3.0/gems/dm-core-1.2.1/lib/dm-core/adapters.rb:13:in `new'
from /app/vendor/bundle/ruby/2.3.0/gems/dm-core-1.2.1/lib/dm-core.rb:230:in `setup'
from /app/controllers/app.rb:38:in `<top (required)>'
from /app/config.ru:1:in `require'
from /app/config.ru:1:in `block in <main>'
from /app/vendor/bundle/ruby/2.3.0/gems/rack-1.6.4/lib/rack/builder.rb:55:in `instance_eval'
from /app/vendor/bundle/ruby/2.3.0/gems/rack-1.6.4/lib/rack/builder.rb:55:in `initialize'
from /app/config.ru:1:in `new'
from /app/config.ru:1:in `<main>'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/rack/adapter/loader.rb:33:in `eval'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/rack/adapter/loader.rb:33:in `load'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/rack/adapter/loader.rb:42:in `for'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/thin/controllers/controller.rb:170:in `load_adapter'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/thin/controllers/controller.rb:74:in `start'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/thin/runner.rb:200:in `run_command'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/lib/thin/runner.rb:156:in `run!'
from /app/vendor/bundle/ruby/2.3.0/gems/thin-1.6.4/bin/thin:6:in `<top (required)>'
from /app/vendor/bundle/ruby/2.3.0/bin/thin:23:in `load'
from /app/vendor/bundle/ruby/2.3.0/bin/thin:23:in `<main>'
Using rack adapter
=====> end my-app web container output
To ssh://dokku#my-host.com:22/my-app
! [remote rejected] patch-dm-postgres-adapter-deploy -> master (pre-receive hook declined)
error: failed to push some refs to 'ssh://dokku#my-host.com:22/my-app'
The ruby error is because it can't require dm-postgres-adapter, because its gem has not been installed.
Bundler also states that Gems in the groups development, test and production were not installed..
Here's what I know:
I do have a local .bundler/config containing BUNDLE_WITHOUT: production, but this is .gitignore'd.
On the dokku instance, this is what dokku run my-app bundle config gives me:
Settings are listed in order of priority. The top value will be used.
without
Set for your local app (/app/.bundle/config): "development:test:production"
Set via BUNDLE_WITHOUT: "development:test"
Set for the current user (/app/.bundle/config): "development:test:production"
...
I can understand where the development:test of the without clause comes from, but I'm really at a lost to understand how and why production is also there.
I also tried to set an ENV var BUNDLE_WITHOUT: development:test before deploying for the 1st time. It's taken into account, however it's preceded by the local bundler config, which already excludes production.
I solved this by manually editing /home/dokku/my-app/cache/.bundle/config and remove production:
BUNDLE_WITHOUT: development:test
After pushing again, Bundler successfully installed my production gem.
But I don't want to have to manually edit configuration files on the server to get it to work.
So, the QUESTION:
Why is production group ignored by Bundler when deploying on Dokku?
How can I force my production gems to be installed?
Thanks!
We use the heroku buildpack, so its possible the latest buildpack has an issue with setting proper defaults?
I am experiencing problems with the "heroku run rake db:migrate" command.
It complains about an " ! Heroku client internal error", see below for the entire thing. Git push and heroku create work (see below), but finally rake db:migrate crashes.
What can I do?
All the best
Stefan
Below is what I enter and get from Heroku.
C:\Sites\demo_app_rt32>git push -u origin master
Enter passphrase for key '/z/.ssh/id_rsa':
Counting objects: 102, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (91/91), done.
Writing objects: 100% (102/102), 32.37 KiB, done.
Total 102 (delta 8), reused 0 (delta 0)
To git#github.com:StefanHelber/demo_app_rt32.git
* [new branch] master -> master
Branch master set up to track remote branch master from origin.
C:\Sites\demo_app_rt32>heroku create --stack cedar
Creating murmuring-thicket-9165... done, stack is cedar
http://murmuring-thicket-9165.herokuapp.com/ | git#heroku.com:murmuring-thicket-
9165.git
Git remote heroku added
C:\Sites\demo_app_rt32>git push heroku master
Enter passphrase for key '/z/.ssh/id_rsa':
Counting objects: 102, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (91/91), done.
Writing objects: 100% (102/102), 32.37 KiB, done.
Total 102 (delta 8), reused 0 (delta 0)
-----> Heroku receiving push
-----> Ruby/Rails app detected
-----> Installing dependencies using Bundler version 1.2.1
Running: bundle install --without development:test --path vendor/bundle -
-binstubs bin/
Fetching gem metadata from https://rubygems.org/.........
Installing rake (0.9.2.2)
Installing i18n (0.6.1)
Installing multi_json (1.3.6)
Installing activesupport (3.2.3)
Installing builder (3.0.3)
Installing activemodel (3.2.3)
Installing erubis (2.7.0)
Installing journey (1.0.4)
Installing rack (1.4.1)
Installing rack-cache (1.2)
Installing rack-test (0.6.2)
Installing hike (1.2.1)
Installing tilt (1.3.3)
Installing sprockets (2.1.3)
Installing actionpack (3.2.3)
Installing mime-types (1.19)
Installing polyglot (0.3.3)
Installing treetop (1.4.10)
Installing mail (2.4.4)
Installing actionmailer (3.2.3)
Installing arel (3.0.2)
Installing tzinfo (0.3.33)
Installing activerecord (3.2.3)
Installing activeresource (3.2.3)
Using bundler (1.2.1)
Installing coffee-script-source (1.3.3)
Installing execjs (1.4.0)
Installing coffee-script (2.2.0)
Installing rack-ssl (1.3.2)
Installing json (1.7.5) with native extensions
Installing rdoc (3.12)
Installing thor (0.14.6)
Installing railties (3.2.3)
Installing coffee-rails (3.2.2)
Installing jquery-rails (2.0.2)
Installing pg (0.12.2) with native extensions
Installing rails (3.2.3)
Installing sass (3.2.1)
Installing sass-rails (3.2.4)
Installing uglifier (1.2.3)
Your bundle is complete! It was installed into ./vendor/bundle
Post-install message from rdoc:
Depending on your version of ruby, you may need to install ruby rdoc/ri data:
<= 1.8.6 : unsupported
= 1.8.7 : gem install rdoc-data; rdoc-data --install
= 1.9.1 : gem install rdoc-data; rdoc-data --install
>= 1.9.2 : nothing to do! Yay!
Cleaning up the bundler cache.
-----> Writing config/database.yml to read from DATABASE_URL
-----> Preparing app for Rails asset pipeline
Running: rake assets:precompile
Asset precompilation completed (13.78s)
-----> Rails plugin injection
Injecting rails_log_stdout
Injecting rails3_serve_static_assets
-----> Discovering process types
Procfile declares types -> (none)
Default types for Ruby/Rails -> console, rake, web, worker
-----> Compiled slug size: 9.0MB
-----> Launching... done, v5
http://murmuring-thicket-9165.herokuapp.com deployed to Heroku
To git#heroku.com:murmuring-thicket-9165.git
* [new branch] master -> master
C:\Sites\demo_app_rt32>heroku run rake db:migrate
Running `rake db:migrate` attached to terminal... up, run.1
! Heroku client internal error.
! Search for help at: https://help.heroku.com
! Or report a bug at: https://github.com/heroku/heroku/issues/new
Error: A connection attempt failed because the connected party did not
properly respond after a period of time, or established connection failed becau
se connected host has failed to respond. - connect(2) (Errno::ETIMEDOUT)
Backtrace: C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/client/rendezvous.rb:39:in `initialize'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/client/rendezvous.rb:39:in `open'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/client/rendezvous.rb:39:in `block in start'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/timeout.rb:68:in `ti
meout'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/client/rendezvous.rb:31:in `start'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/command/run.rb:125:in `rendezvous_session'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/command/run.rb:112:in `run_attached'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/command/run.rb:21:in `index'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/command.rb:206:in `run'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/lib/heroku/cli.rb:28:in `start'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/heroku-2.3
2.4/bin/heroku:16:in `<top (required)>'
C:/RailsInstaller/Ruby1.9.3/bin/heroku:19:in `load'
C:/RailsInstaller/Ruby1.9.3/bin/heroku:19:in `<main>'
Command: heroku run rake db:migrate
Version: heroku-toolbelt/2.32.4 (i386-mingw32) ruby/1.9.3 autoupdate
C:\Sites\demo_app_rt32>
See https://devcenter.heroku.com/articles/oneoff-admin-ps
The heroku run process opens a connection to Heroku on port 5000. If
your local network or ISP is blocking port 5000, or you are
experiencing a connectivity issue, you will see an error similar to:
$ heroku run rails console
Running rails console attached to terminal...
Timeout awaiting process
You can test your connection to Heroku by trying to connect directly
to port 5000 by using telnet to rendezvous.runtime.heroku.com. A
successful session will look like this:
$ telnet rendezvous.runtime.heroku.com 5000
Trying 50.19.103.36...
Connected to ec2-50-19-103-36.compute-1.amazonaws.com.
Escape character is '^]'.
If you do not get this output, your computer is being blocked from
accessing our services. We recommend contacting your IT department,
ISP, or firewall manufacturer to move forward with this issue.