Skyline Console - Modern Dashboard for OpenStack
Skyline Console is one part of OpenStack Modern Dashboard, which provides a web based user interface to OpenStack services including Nova, Swift, Keystone, etc. Skyline was optimized by UI and UE, support OpenStack Train+.
Skyline’s mascot is the nine-color deer. The nine-color deer comes from Dunhuang mural “the nine-color king deer”, whose moral is Buddhist cause-effect and gratefulness, which is consistent with 99cloud’s philosophy of embracing and feedback community since its inception. We also hope Skyline can keep light, elegant and powerful as the nine-color deer, to provide a better dashboard for the openstack community and users.
More about Skyline: https://docs.openstack.org/skyline-console/latest/
Prerequisites:
- OpenStack Environment Installed
- Instance to run Skyline (image: Ubuntu 20.04)
- Skyline server can reach Keystone API
Setup Skyline on Ubuntu 20.04
Let’s take a look at the steps required to setup Skyline. The steps look something like the following:
1. Add Skyline Account
Login to your Openstack administration node to manage OpenStack from CLI. In my case is Controller node
### Source the admin credentials
(kolla-venv) root@controller1:~# source /etc/kolla/admin-openrc.sh
### Create the skyline user
(kolla-venv) root@controller1:~# openstack user create \
--domain default --password-prompt skyline
User Password:
Repeat User Password:
+---------------------+----------------------------------+
| Field | Value |
+---------------------+----------------------------------+
| domain_id | default |
| enabled | True |
| id | 1cdbd41bcb374603af22c2e05e835823 |
| name | skyline |
| options | {} |
| password_expires_at | None |
+---------------------+----------------------------------+
### Add the admin role to the skyline user
(kolla-venv) root@controller1:~# openstack role add \
--project service --user skyline admin
2. Configure MySQL DB
Login to your Skyline Server
### Install MySQL
$ sudo -i
# apt-get install mariadb-server -y
### Create database
# mysql -u root -p
Enter password:
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 36
Server version: 10.3.38-MariaDB-0ubuntu0.20.04.1 Ubuntu 20.04
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> CREATE DATABASE IF NOT EXISTS skyline DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci;
Query OK, 1 row affected (0.000 sec)
### Grant proper access to the databases
MariaDB [(none)]> GRANT ALL PRIVILEGES ON skyline.* TO 'skyline'@'localhost' IDENTIFIED BY 'Skyline123';
Query OK, 0 rows affected (0.003 sec)
MariaDB [(none)]> GRANT ALL PRIVILEGES ON skyline.* TO 'skyline'@'%' IDENTIFIED BY 'Skyline123';
Query OK, 0 rows affected (0.001 sec)
3. Setup Docker
### Install docker
# apt-get install docker.io -y
# docker version
Client:
Version: 24.0.5
API version: 1.43
Go version: go1.20.3
Git commit: 24.0.5-0ubuntu1~20.04.1
Built: Mon Aug 21 19:50:14 2023
OS/Arch: linux/amd64
Context: default
Server:
Engine:
Version: 24.0.5
API version: 1.43 (minimum version 1.12)
Go version: go1.20.3
Git commit: 24.0.5-0ubuntu1~20.04.1
Built: Mon Aug 21 19:50:14 2023
OS/Arch: linux/amd64
Experimental: false
containerd:
Version: 1.7.2
GitCommit:
runc:
Version: 1.1.7-0ubuntu1~20.04.1
GitCommit:
docker-init:
Version: 0.19.0
GitCommit:
4. Setup Skyline app
Clone skyline repository from https://opendev.org/openstack/skyline-apiserver
# git clone https://opendev.org/skyline/skyline-apiserver
Edit the /etc/skyline/skyline.yaml
file in linux server. We can refer to the sample file, and modify the following parameters according to the actual environment:
- database_url
- keystone_url
- default_region
- interface_type
- system_project_domain
- system_project
- system_user_domain
- system_user_name
- system_user_password
Configure Skyline usingskyline.yaml
file
# mkdir /etc/skyline; cp skyline-apiserver/etc/skyline.yaml.sample /etc/skyline/skyline.yaml
Below config are going to provide our openstack environment keystone_url
to fetch all endpint so skyline will be able to access openstack. Here is in my case:
### cat /etc/skyline/skyline.yaml
default:
access_token_expire: 3600
access_token_renew: 1800
cafile: ''
cors_allow_origins: []
database_url: mysql://skyline:Skyline123@localhost:3306/skyline
debug: false
log_dir: ./log
log_file: skyline.log
policy_file_path: /etc/skyline/policy
policy_file_suffix: policy.yaml
prometheus_basic_auth_password: ''
prometheus_basic_auth_user: ''
prometheus_enable_basic_auth: false
prometheus_endpoint: http://localhost:9091
secret_key: aCtmgbcUqYUy_HNVg5BDXCaeJgJQzHJXwqbXr0Nmb2o
session_name: session
ssl_enabled: true
openstack:
base_domains:
- heat_user_domain
default_region: RegionOne
enforce_new_defaults: true
extension_mapping:
floating-ip-port-forwarding: neutron_port_forwarding
fwaas_v2: neutron_firewall
qos: neutron_qos
vpnaas: neutron_vpn
interface_type: public
keystone_url: https://public.achikam.net:5000/v3/
nginx_prefix: /api/openstack
reclaim_instance_interval: 604800
service_mapping:
baremetal: ironic
compute: nova
container: zun
container-infra: magnum
database: trove
dns: designate
identity: keystone
image: glance
instance-ha: masakari
key-manager: barbican
load-balancer: octavia
network: neutron
object-store: swift
orchestration: heat
placement: placement
sharev2: manilav2
volumev3: cinder
sso_enabled: false
sso_protocols:
- openid
sso_region: RegionOne
system_admin_roles:
- admin
- system_admin
system_project: service
system_project_domain: Default
system_reader_roles:
- system_reader
system_user_domain: Default
system_user_name: skyline
system_user_password: Skyline123
setting:
base_settings:
- flavor_families
- gpu_models
- usb_models
flavor_families:
- architecture: x86_architecture
categories:
- name: general_purpose
properties: []
- name: compute_optimized
properties: []
- name: memory_optimized
properties: []
- name: high_clock_speed
properties: []
- architecture: heterogeneous_computing
categories:
- name: compute_optimized_type_with_gpu
properties: []
- name: visualization_compute_optimized_type_with_gpu
properties: []
gpu_models:
- nvidia_t4
usb_models:
- usb_c
5. Deploy Skyline app
Run the skyline_bootstrap container to bootstrap
### Run the skyline_bootstrap container to bootstrap
# rm -rf /tmp/skyline && mkdir /tmp/skyline && mkdir /var/log/skyline
# docker run -d --name skyline_bootstrap -e KOLLA_BOOTSTRAP="" -v /etc/skyline/skyline.yaml:/etc/skyline/skyline.yaml --net=host 99cloud/skyline:latest
### Check bootstrap is normal `exit 0`
# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
0122f89e1daf 99cloud/skyline:latest "start_service.sh" 7 seconds ago Exited (0) 5 seconds ago skyline_bootstrap
# docker logs skyline_bootstrap
+ echo '/usr/local/bin/gunicorn -c /etc/skyline/gunicorn.py skyline_apiserver.main:app'
+ mapfile -t CMD
++ tail /run_command
++ xargs -n 1
+ [[ -n 0 ]]
+ cd /skyline-apiserver/
+ make db_sync
alembic -c skyline_apiserver/db/alembic/alembic.ini upgrade head
2023-12-26 01:38:33.711 | INFO | alembic.runtime.migration:__init__:205 - Context impl MySQLImpl.
2023-12-26 01:38:33.712 | INFO | alembic.runtime.migration:__init__:208 - Will assume non-transactional DDL.
2023-12-26 01:38:33.843 | INFO | alembic.runtime.migration:run_migrations:619 - Running upgrade -> 000, init
+ exit 0
Run the skyline service after bootstrap is complete
- If you need to modify skyline port, add
-e LISTEN_ADDRESS=<ip:port>
in the following commandLISTEN_ADDRESS
defaults to 0.0.0.0:9999 - If you need to modify the policy rules of a service, add
-v /etc/skyline/policy:/etc/skyline/policy
in the following command
Rename the service policy yaml
file to <service_name>_policy.yaml
, and place it in /etc/skyline/policy
folder
### Remove bootstrap container
# docker rm -f skyline_bootstrap
### Run skyline container using docker
# docker run -d --name skyline --restart=always -v /etc/skyline/skyline.yaml:/etc/skyline/skyline.yaml --net=host 99cloud/skyline:latest
4043b16b3b231e12f3b88441b79486e4122de15e0d21b9ad791d13a5466aaf96
6. Verify Skyline app
### Verify skyline app was running
# docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
4043b16b3b23 99cloud/skyline:latest "start_service.sh" 4 seconds ago Up 3 seconds skyline
We can now access the dashboard: http://<IP_ADDRESS>:9999/base/overview-admin
Used OpenStack user credentials.
Using Skyline we can set password very easy way when creating Instance (^_^)
Also using Skyline we can choose manually where Compute to running our new Instance (^_^). Continue until last form and click Confirm
Verify New Instance was successfully running
Verify from Horizon Dashboard
Let’s Enjoy Skyline Dashboard for your OpenStack management GUI
References :