本文介绍Dashboard 安装步骤,Dashboard 仅需在控制节点安装。
在按照本教程安装之前,请确保完成以下配置:
【Openstack Train安装】三、openstack安装
【Openstack Train安装】四、MariaDB/RabbitMQ 安装
【Openstack Train安装】五、Memcached/Etcd安装
【Openstack Train安装】六、Keystone安装
【Openstack Train安装】八、placement安装
【Openstack Train安装】十、Neutron安装
安装环境如下
|--------------------|------------|
| VMware Workstation | V17.0 |
| 本机系统 | win11 |
| 虚拟机系统 | CentOS 7.5 |
一、安装dashboard
安装包:
bash
yum install openstack-dashboard -y
对/etc/openstack-dashboard/local_settings进行如下修改:
1、注释掉39行的"ALLOWED_HOSTS",如下图:
2、将以下内容添加到23行以下:
bash
WEBROOT = '/dashboard/'
SESSION_TIMEOUT = 86400
OPENSTACK_HOST = "controller"
ALLOWED_HOSTS = ['*', ]
SESSION_ENGINE = 'django.contrib.sessions.backends.file'
CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
'LOCATION': 'controller:11211',
}
}
OPENSTACK_API_VERSIONS = {
"identity": 3,
"image": 2,
"volume": 3,
}
OPENSTACK_KEYSTONE_URL = "http://%s:5000/v3" % OPENSTACK_HOST
OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT = True
OPENSTACK_KEYSTONE_DEFAULT_DOMAIN = "Default"
OPENSTACK_KEYSTONE_DEFAULT_ROLE = "user"
OPENSTACK_NEUTRON_NETWORK = {
'enable_router': True,
'enable_quotas': True,
'enable_rbac_policy': True,
'enable_distributed_router': False,
'enable_ha_router': False,
'enable_ipv6': False,
'enable_lb': False,
'enable_firewall': False,
'enable_vpn': False,
'enable_fip_topology_check': True,
'default_dns_nameservers': [],
'supported_provider_types': ['*'],
'segmentation_id_range': {},
'extra_provider_types': {},
'supported_vnic_types': ['*'],
'physical_networks': [],
}
OPENSTACK_CINDER_FEATURES = {
'enable_backup': True,
}
TIME_ZONE = "Asia/Shanghai"
编辑/etc/httpd/conf.d/openstack-dashboard.conf,在第四行添加以下内容:
bash
WSGIApplicationGroup %{GLOBAL}
重启服务httpd和memcached:
bash
systemctl restart httpd.service memcached.service
二、验证
打开浏览器,访问网站 http://192.168.59.20/dashboard/ ,如下图:
用户admin,密码123456,登录:
如下所示,安装完成。