2
1

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.

ローカル開発環境設定メモ

Last updated at Posted at 2015-06-22

CentOSを導入してます。

ボックスの追加

vagrant box add <名前> <アドレス>

仮想ボックスの初期化

vagrant init <名前>

Vagrantfileの編集

vi Vagrantfile
//IPアドレスを編集する

ボックスの作成

vagrant up

システムを最新の状態に

sudo yum update -y

ネットワークの設定

sudo vi /etc/resolv.conf
options single-request-reopen
(centosのver6から速くなる設定らしい)

ファイアウォールを切る(開発用)

sudo service iptables stop

以降自動で設定が使われるように

sudo chkconfig iptables off

今の仮想マシンに入ってるものチェック

yum list installed

yum list installed | grep httpd
//特定のもの(httpd)のチェック

httpdのインストール

sudo yum install -y httpd

httpdを立ち上げる

sudo service httpd start

再起動しても有効に

sudo chkconfig httpd on

vagrantユーザがこちらにアクセスできるように

sudo chown -R vagrant:vagrant /var/www/html

情報確認

yum info プログラミング言語(phpとか)

zipとかのゲット

wget <httpアドレス>

epelのゲット

wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm

remiのゲット

wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm

epelの使用

sudo rpm -Uvh epel-release-6-8.noarch.rpm

remiの使用

sudo rpm -Uvh remi-release-6.rpm

epelのenabled=0にして他のものを使えないように

sudo vi /etc/yum.repos.d/epel.repo

2
1
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
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?