Qiita Teams that are logged in
You are not logged in to any team

Log in to Qiita Team
Community
OrganizationAdvent CalendarQiitadon (β)
Service
Qiita JobsQiita ZineQiita Blog
5
Help us understand the problem. What is going on with this article?
@sizukutamago

herokuにlaravelとMysqlの環境を構築する

More than 3 years have passed since last update.

herokuにデプロイする

herokuアプリを作成

heroku create [アプリ名] --buildpack https://github.com/heroku/heroku-buildpack-php
git add .
git commit -m ''
git push heroku master
heroku config:set APP_KEY=$(php artisan key:generate --show)

確認

heroku open

Mysql

クレジットカードを登録(vプリカでも可)

heroku addons:add cleardb
heroku config

でCLEARDB_DATABASE_URLを確認

CLEARDB_DATABASE_URL: mysql://[DB_USERNAME]:[DB_PASSWORD]@[DB_HOST]/[DB_DATABASE]?reconnect=true

から

heroku config:set DB_USERNAME=[DB_USERNAME]

の様に設定していく

APP_ENV = heroku
LANG = ja_JP.UTF-8
TZ = Asia/Tokyo

これで完成

5
Help us understand the problem. What is going on with this article?
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
tambourine
私たちは好奇心を武器に、あたらしいことが大好きな仲間たちと「世界を変えるアイデア」をカタチにするテクノロジスト集団です。

Comments

No comments
Sign up for free and join this conversation.
Sign Up
If you already have a Qiita account Login
5
Help us understand the problem. What is going on with this article?