2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Github + Rails + Heroku Buttonの作り方

Last updated at Posted at 2019-05-03

先日作ったWikiアプリをHerokuボタンを使ったHerokuデプロイができるようにしてみます。

Wikiシステムの作り方は、こちら

git commit log

Heroku Button とは?

Heroku Button を使用すると、アプリケーションを Heroku プラットフォームで開発して運用するまでの期間を簡単に短縮できます。Heroku Button とは、コードのデプロイ方法や設定方法を定義するごく小さなファイルで拡張された、ソースコードリポジトリへのポインターです。Heroku Button をクリックすると、アプリケーションのデプロイを開始したり、アプリケーションの設定オプションを表示したり、実行中のアプリケーションを Web に配信したりできます。

https://jp.heroku.com/elements/buttons

実装してみる

REAMEにボタンを設置します。

$ touch ./README.md
./README.md
+ [![Heroku Deploy](https://www.herokucdn.com/deploy/button.png)](https://heroku.com/deploy?template=https://github.com/fukmaru/wiki)

template=[GithubのURL] をGETパラメータとして指定します。

** app.json を作って、テンプレートを作ります。**

https://devcenter.heroku.com/articles/heroku-button

$ touch ./app.json
./
{
  "name": "wiki",
  "description": "Rails Wiki System",
  "website": "https://github.com/fukmaru/wiki",
  "repository": "https://github.com/fukmaru/wiki",
  "logo": "https://github.com/fukmaru/wiki/blob/master/public/icon_512x512.png",
  "success_url": "/",
  "keywords": [
    "wiki",
    "tool"],
  "addons": [
    "heroku-postgresql"
  ]
}

git commit log

Wikiサービス作りました

(小さく告知させてください:ear:)
簡単なWiki検索を、社内コミュニケーションチャネルから検索できるツールで、「Poii.io」と言います。

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?