LoginSignup
12
12

More than 5 years have passed since last update.

ansible pyenvを使った環境に依存しないインストール

Last updated at Posted at 2013-07-27
install

# pyenvするのに必要なパッケージ
sudo yum install -y vim-enhanced gcc gcc-c++ make git patch openssl-devel zlib-devel readline-devel sqlite-devel bzip2-devel

# pyenv インストール
cd ~
git clone git://github.com/yyuu/pyenv.git .pyenv
echo 'export PATH="$HOME/.pyenv/bin:$PATH"' >> ~/.bash_profile
echo 'eval "$(pyenv init -)"' >> ~/.bash_profile
. ~/.bash_profile

# pyenvで python 2.7.5 を入れる
VERSION=2.7.5
pyenv install $VERSION
pyenv rehash
pyenv global $VERSION

# ansibleに必要なモジュールをpipで入れる
pip install paramiko jinja2 PyYAML pycrypto markupsafe

# ansible のインストール
cd ~
git clone git://github.com/ansible/ansible.git
cd ansible
# 環境変数設定
. ./hacking/env-setup
echo ". ~/ansible/hacking/env-setup -q" >>~/.bashrc
12
12
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
12
12