在上一篇文章分享了neutron网络服务的安装配置,本文分享openstack的horizon(dashboard)web界面管理服务,方便在浏览器操作
---------------------- 完美的分割线 ------------------------
7.0.horizon(dashboard)概述
# mitaka中文版文档
# https://docs.openstack.org/mitaka/zh_CN/install-guide-rdo/neutron-controller-install.html
# rocky版-用户引导页
# https://docs.openstack.org/install-guide/openstack-services.html#minimal-deployment-for-rocky
# rocky版horizon(dashboard)安装文档
# https://docs.openstack.org/horizon/rocky/install/
系统环境要求:
1)Python2.7或者3.5以上
2)Django1.11或者2.0以上(Django 1.8 to 1.10 are no longer supported since Rocky release.)
3)可用的keystone节点服务
4)以下服务可以选择:
cinder: Block Storage
glance: Image Management
neutron: Networking
nova: Compute
swift: Object Storage
Horizon also supports many other OpenStack services via plugins. For more information, see the Plugin Registry.
7.1.安装dashboard WEB控制台
1)安装dashboard软件包
yum install openstack-dashboard -y
2)修改配置文件/etc/openstack-dashboard/local_settings
# 检查确认有以下配置
vim /etc/openstack-dashboard/local_settings
-------------------------------------
ALLOWED_HOSTS = ['*', ]
SESSION_ENGINE = 'django.contrib.sessions.backends.cache'
OPENSTACK_API_VERSIONS = {
"identity": 3,
"image": 2,
"volume": 2,
}
OPENSTACK_HOST = "controller"
OPENSTACK_KEYSTONE_URL = "http://%s:5000/v3" % OPENSTACK_HOST
OPENSTACK_KEYSTONE_DEFAULT_ROLE = "user"
OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT = True
OPENSTACK_KEYSTONE_DEFAULT_DOMAIN = "default"
CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
'LOCATION': 'controller:11211',
}
}
OPENSTACK_NEUTRON_NETWORK = {
'enable_router': False,
'enable_quotas': False,
'enable_distributed_router': False,
'enable_ha_router': False,
'enable_fip_topology_check': False,
'enable_lb': False,
'enable_firewall': False,
'enable_vpn': False,
}
TIME_ZONE = "Asia/Shanghai"
--------------------------------------
# 配置选项:
配置dashboard运行在192.168.1.81上(192.168.1.81为OS主机名)
配置允许登陆dashboard的主机
配置memcached存储服务
启用第3版认证API
启用对域的支持
配置API版本
通过仪表盘创建用户时的默认域配置为 default
通过仪表盘创建的用户默认角色配置为 user
如果您选择网络参数1,禁用支持3层网络服务:
可以选择性地配置时区,不能用CST否则无法启动httpd服务
3)修改/etc/httpd/conf.d/openstack-dashboard.conf
# 增加以下内容
vim /etc/httpd/conf.d/openstack-dashboard.conf
-------------------------------------
WSGIApplicationGroup %{GLOBAL}
-------------------------------------
4)重启web服务器以及会话存储服务
systemctl restart httpd.service memcached.service
systemctl status httpd.service memcached.service
5)检查dashboard是否可用
# 在浏览器中输入下面的地址:用户名和密码都是admin,域名用default
http://controller:80/dashboard
# 浏览器页面如下:
# 登录后显示这样一个摘要信息:
# 新安装的默认里面基本是空的,需要后续手动添加扩充
6)其他可选的dashboard配置
https://docs.openstack.org/horizon/rocky/install/next-steps.html
======== 完毕,呵呵呵呵 ========