質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Heroku

HerokuはHeroku社が開発と運営を行っているPaaSの名称です。RubyやNode.js、Python、そしてJVMベース(Java、Scala、Clojureなど)の複数のプログラミング言語をサポートしている。

PostgreSQL

PostgreSQLはオープンソースのオブジェクトリレーショナルデータベース管理システムです。 Oracle Databaseで使われるPL/SQLを参考に実装されたビルトイン言語で、Windows、 Mac、Linux、UNIX、MSなどいくつものプラットフォームに対応しています。

Q&A

解決済

1回答

885閲覧

Heroku デプロイ

yakumo02

総合スコア103

Heroku

HerokuはHeroku社が開発と運営を行っているPaaSの名称です。RubyやNode.js、Python、そしてJVMベース(Java、Scala、Clojureなど)の複数のプログラミング言語をサポートしている。

PostgreSQL

PostgreSQLはオープンソースのオブジェクトリレーショナルデータベース管理システムです。 Oracle Databaseで使われるPL/SQLを参考に実装されたビルトイン言語で、Windows、 Mac、Linux、UNIX、MSなどいくつものプラットフォームに対応しています。

0グッド

0クリップ

投稿2019/12/15 09:37

編集2019/12/15 11:09

Herokuを使ってデプロイしようとしたところ以下のエラーが出ました
初めて使うのでよくわかりません 何が原因なのでしょうか ご教授願います
下記のサイトを参考にしました
https://qiita.com/kazukimatsumoto/items/a0daa7281a3948701c39

ターミナルで$heroku login を実行した場合ターミナルでeメールとパスワードの入力を求められるみたいですが自分は以下のページに遷移します
$heroku -vをするとバージョン情報が表示されるのでインストールは成功してると思います
イメージ説明

Enumerating objects: 894, done. Counting objects: 100% (894/894), done. Delta compression using up to 4 threads Compressing objects: 100% (845/845), done. Writing objects: 100% (894/894), 128.23 KiB | 2.85 MiB/s, done. Total 894 (delta 520), reused 0 (delta 0) remote: Compressing source files... done. remote: Building source: remote: remote: ! error fetching custom buildpack https://git.heroku.com/whispering-ridge-73721.git remote: remote: ! Push failed remote: Verifying deploy... remote: remote: ! Push rejected to whispering-ridge-73721. remote: To https://git.heroku.com/whispering-ridge-73721.git ! [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to 'https://git.heroku.com/whispering-ridge-73721.git'

Gemfile

source 'https://rubygems.org' git_source(:github) do |repo_name| repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") "https://github.com/#{repo_name}.git" end # Bundle edge Rails instead: gem 'rails', github: 'rails/rails' gem 'rails', '~> 5.0.7', '>= 5.0.7.2' # Use mysql as the database for Active Record # gem 'mysql2', '>= 0.3.18', '< 0.6.0' # Use Puma as the app server gem 'puma', '~> 3.0' # Use SCSS for stylesheets gem 'sass-rails', '~> 5.0' # Use Uglifier as compressor for JavaScript assets gem 'uglifier', '>= 1.3.0' # Use CoffeeScript for .coffee assets and views gem 'coffee-rails', '~> 4.2' # See https://github.com/rails/execjs#readme for more supported runtimes # gem 'therubyracer', platforms: :ruby # Use jquery as the JavaScript library gem 'jquery-rails' # Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks gem 'turbolinks', '~> 5' # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder gem 'jbuilder', '~> 2.5' # Use Redis adapter to run Action Cable in production # gem 'redis', '~> 3.0' # Use ActiveModel has_secure_password # gem 'bcrypt', '~> 3.1.7' # Use Capistrano for deployment # gem 'capistrano-rails', group: :development group :development, :test do # Call 'byebug' anywhere in the code to stop execution and get a debugger console gem 'byebug', platform: :mri gem 'pry-rails' end group :development do # Access an IRB console on exception pages or by using <%= console %> anywhere in the code. gem 'web-console', '>= 3.3.0' gem 'listen', '~> 3.0.5' # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring gem 'spring' gem 'spring-watcher-listen', '~> 2.0.0' end gem 'carrierwave' gem 'fog-aws' # Windows does not include zoneinfo files, so bundle the tzinfo-data gem gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] gem 'haml-rails' gem "font-awesome-rails" gem 'devise' gem 'carrierwave' gem 'mini_magick' gem 'rspec-rails', '~> 3.5' gem 'rails-controller-testing' gem 'factory_bot_rails' gem 'faker' group :test, :development do gem 'capybara' end # group :production do # gem 'unicorn', '5.4.1' # end # group :development, :test do # gem 'capistrano' # gem 'capistrano-rbenv' # gem 'capistrano-bundler' # gem 'capistrano-rails' # gem 'capistrano3-unicorn' # end group :production do gem 'pg' end group :development, :test do gem 'mysql2' end

database.yml

# MySQL. Versions 5.0 and up are supported. # # Install the MySQL driver # gem install mysql2 # # Ensure the MySQL gem is defined in your Gemfile # gem 'mysql2' # # And be sure to use new-style password hashing: # http://dev.mysql.com/doc/refman/5.7/en/old-client.html # default: &default adapter: mysql2 encoding: utf8 pool: 5 username: root password: socket: /tmp/mysql.sock development: <<: *default database: MyApri_development # Warning: The database defined as "test" will be erased and # re-generated from your development database when you run "rake". # Do not set this db to the same as development or production. test: <<: *default database: MyApri_test # As with config/secrets.yml, you never want to store sensitive information, # like your database password, in your source code. If your source code is # ever seen by anyone, they now have access to your database. # # Instead, provide the password as a unix environment variable when you boot # the app. Read http://guides.rubyonrails.org/configuring.html#configuring-a-database # for a full rundown on how to provide these environment variables in a # production deployment. # # On Heroku and other platform providers, you may have a full connection URL # available as an environment variable. For example: # # DATABASE_URL="mysql2://myuser:mypass@localhost/somedatabase" # # You can use this database configuration with: # # production: # url: <%= ENV['DATABASE_URL'] %> # production: <<: *default database: MyApri_production username: MyApri password: <%= ENV['MYAPRI_DATABASE_PASSWORD'] %> adapter: postgresql encoding: unicode pool: 5

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

退会済みユーザー

退会済みユーザー

2019/12/15 11:07

ビルドパック入れてないのでは?
yakumo02

2019/12/15 11:10

コメントありがとうございます すみません、どういう意味でしょうか?
yakumo02

2019/12/15 11:46

入れてみましたができませんでした
guest

回答1

0

自己解決

heroku login --interactive
でログインできました
回答が来なかったのが不思議なくらい簡単でした

投稿2019/12/17 00:50

編集2019/12/20 08:51
yakumo02

総合スコア103

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

退会済みユーザー

退会済みユーザー

2019/12/20 10:29

すでにターミナルでのログイン経験ある人(ビルドが実行されている)にログの仕方を教えるバカはいません
yakumo02

2019/12/20 12:47

そうなんですか!(◎_◎;) もっと勉強して、まともな質問ができるようにします!
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問