OpenStack中magnum组件安装

OpenStack中magnum组件安装

以下命令建议在干净的OS上操作,因为devstack使用的都是最新的环境依赖。不然安装过程中会出现版本不匹配问题

1.安装所需OS环境

sudo apt-get update
sudo apt-get install -y python-dev libssl-dev libxml2-dev \
                        libmysqlclient-dev libxslt-dev libpq-dev git \
                        libffi-dev gettext build-essential

2.安装python包管理工具

apt-get install python-pip

3.安装通用环境

apt-get install python-virtualenv python-flake8 python-tox testrepository git-review

4.git软件源

cd ~
git clone https://git.openstack.org/openstack/magnum
cd magnum


5.使用tox进行所有单元测试(可以略过)

# run all tests (unit and pep8)
tox
# run a specific test for Python 2.
tox -epy27 -- test_conductor
# run all the Python 2.7 unit tests (in parallel!)
tox -epy27 -- --parallel

6.使用devstack安装

# Create a root directory for devstack if needed
sudo mkdir -p /opt/stack
sudo chown $USER /opt/stack
git clone https://git.openstack.org/openstack-dev/devstack /opt/stack/devstack

7.配置local.conf文件

#把stackrc文件中所有的git协议换成https协议,因为有墙
sed -i 's/git:\/\/git.openstack.org/https:\/\/git.openstack.org/g' stackrc

cat > /opt/stack/devstack/local.conf << END
[[local|localrc]]
DATABASE_PASSWORD=password
RABBIT_PASSWORD=password
SERVICE_TOKEN=password
SERVICE_PASSWORD=password
ADMIN_PASSWORD=password
# magnum requires the following to be set correctly
PUBLIC_INTERFACE=eth0
enable_plugin magnum https://git.openstack.org/openstack/magnum
# Enable barbican service and use it to store TLS certificates
# For details http://docs.openstack.org/developer/magnum/dev/dev-tls.html
enable_plugin ceilometer https://git.openstack.org/openstack/ceilometer
enable_plugin barbican https://git.openstack.org/openstack/barbican VOLUME_BACKING_FILE_SIZE=20G
END
阅读更多
版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/ptmozhu/article/details/52386691
个人分类: OpenStack
想对作者说点什么? 我来说一句

没有更多推荐了,返回首页

不良信息举报

OpenStack中magnum组件安装

最多只允许输入30个字

加入CSDN,享受更精准的内容推荐,与500万程序员共同成长!
关闭
关闭