Update README.rst and bump hacking
First update, we need do more changes in future for documentation. Change-Id: I0dbaab4e2c8462bf4b108c452929e3d16c310375
This commit is contained in:
72
README.rst
72
README.rst
@@ -12,81 +12,79 @@ Freezer - Horizon Dashboard
|
||||
===========================
|
||||
|
||||
freezer-web-ui is a horizon plugin based in django aimed at providing an interaction
|
||||
with freezer
|
||||
with freezer.
|
||||
|
||||
* Issue tracking and feature specifications: https://storyboard.openstack.org/#!/project/openstack/freezer-web-ui
|
||||
* Issue tracking and feature specifications: https://launchpad.net/freezer
|
||||
|
||||
Requirements
|
||||
============
|
||||
|
||||
Freezer Dashboard requires a freezer API client to be installed in the same environment as horizon::
|
||||
Before start, please install git and pip in your Operation System.
|
||||
If your use Ubuntu:
|
||||
|
||||
git clone https://github.com/openstack/python-freezerclient
|
||||
apt install git python3-pip
|
||||
|
||||
If your use RHEL/CentOS:
|
||||
|
||||
dnf install git python3-pip
|
||||
|
||||
Freezer Dashboard requires a freezer API client to be installed in the same
|
||||
environment as Horizon:
|
||||
|
||||
git clone https://opendev.org/openstack/python-freezerclient
|
||||
cd python-freezerclient
|
||||
python setup.py install (is important that freezer API client is installed from source and not with pip and
|
||||
is installed on horizon virtual environment)
|
||||
python3 -m pip install .
|
||||
|
||||
Freezer Dashboard requires a freezer API endpoint which you can install following this steps:
|
||||
Freezer Dashboard requires a freezer API endpoint which you can install
|
||||
following this steps:
|
||||
|
||||
`https://github.com/openstack/freezer-api/blob/master/README.rst
|
||||
<https://github.com/openstack/freezer-api/blob/master/README.rst>`_
|
||||
`https://opendev.org/openstack/freezer-api
|
||||
<https://opendev.org/openstack/freezer-api>`_
|
||||
|
||||
API registration
|
||||
================
|
||||
|
||||
Register freezer api endpoint:
|
||||
If keystone service-create and endpoint-create are not available you can
|
||||
set as a fallback the following on:
|
||||
|
||||
`https://github.com/openstack/freezer-api/blob/master/README.rst#api-registration
|
||||
<https://github.com/openstack/freezer-api/blob/master/README.rst#api-registration>`_
|
||||
|
||||
If keystone service-create and endpoint-create are not available you can set as a fallback the following on::
|
||||
|
||||
# vim /opt/stack/horizon/openstack_dashboard/local/local_settings.py
|
||||
|
||||
# add FREEZER_API_URL = http://<api_url>:<port>
|
||||
vim /etc/horizon/openstack_dashboard/local/local_settings.py
|
||||
|
||||
add FREEZER_API_URL = http://<api_url>:<port>
|
||||
|
||||
Installation
|
||||
============
|
||||
|
||||
In the installation procedure we'll assume your main Horizon dashboard
|
||||
directory is /opt/stack/horizon/openstack_dashboard/dashboards/.
|
||||
directory is /etc/horizon/openstack_dashboard/dashboards/.
|
||||
|
||||
To install freezer dashboard for development you need to do the following:
|
||||
|
||||
To install freezer dashboard for development you need to do the following::
|
||||
git clone https://opendev.org/openstack/freezer-web-ui
|
||||
cd freezer-web-ui
|
||||
cp freezer-web-ui/freezer_ui/enabled/_5050_freezer.py /etc/horizon/openstack_dashboard/enabled/_5050_freezer.py
|
||||
|
||||
# git clone https://github.com/openstack/freezer-web-ui
|
||||
To disable the panel set `DISABLED = True` in /etc/horizon/openstack_dashboard/enabled/_5050_freezer.py
|
||||
|
||||
# cd freezer-web-ui
|
||||
cd /etc/horizon/
|
||||
python3 -m pip install -r requirements.txt
|
||||
|
||||
# cp freezer-web-ui/freezer_ui/enabled/_5050_freezer.py /opt/stack/horizon/openstack_dashboard/enabled/_5050_freezer.py
|
||||
|
||||
# to disable the panel set `DISABLED = True` in /opt/stack/horizon/openstack_dashboard/enabled/_5050_freezer.py
|
||||
|
||||
# cd /opt/stack/horizon/
|
||||
|
||||
# pip install -r requirements.txt
|
||||
|
||||
# make sure freezer is installed from source as detailed in the first step
|
||||
|
||||
# ./run_tests.sh --runserver 0.0.0.0:8000
|
||||
Make sure freezer is installed from source as detailed in the first step
|
||||
|
||||
./run_tests.sh --runserver 0.0.0.0:8000
|
||||
|
||||
A new tab called "Disaster Recovery" will appear on your panels.
|
||||
|
||||
|
||||
Tox
|
||||
===
|
||||
|
||||
1. Run tox::
|
||||
Run tox:
|
||||
|
||||
tox -v
|
||||
|
||||
|
||||
Development under proxy
|
||||
_______________________
|
||||
|
||||
If you are developing or deploying under proxies remember to set no_proxies for::
|
||||
If you are developing or deploying under proxies remember to set no_proxies for:
|
||||
|
||||
freezer-api endpoint
|
||||
keystone endpoint
|
||||
|
@@ -4,8 +4,9 @@ author = OpenStack
|
||||
author_email = openstack-discuss@lists.openstack.org
|
||||
summary = Freezer - Backup as a Service User Interface
|
||||
description_file = README.rst
|
||||
home_page = https://github.com/openstack/freezer-web-ui
|
||||
description-content-type = text/x-rst
|
||||
license = Apache-2
|
||||
url = https://docs.openstack.org/freezer/latest/
|
||||
python_requires = >=3.8
|
||||
classifier =
|
||||
Development Status :: 5 - Production/Stable
|
||||
@@ -23,6 +24,9 @@ classifier =
|
||||
Programming Language :: Python :: 3
|
||||
Programming Language :: Python :: 3.8
|
||||
Programming Language :: Python :: 3.9
|
||||
Programming Language :: Python :: 3.10
|
||||
Programming Language :: Python :: 3.11
|
||||
Programming Language :: Python :: 3.12
|
||||
Topic :: Internet :: WWW/HTTP
|
||||
keywords =
|
||||
horizon
|
||||
|
@@ -1,13 +1,8 @@
|
||||
# The order of packages is significant, because pip processes them in the order
|
||||
# of appearance. Changing the order has an impact on the overall integration
|
||||
# process, which may cause wedges in the gate later.
|
||||
|
||||
hacking>=3.0.1,<3.1.0 # Apache-2.0
|
||||
hacking>=7.0.0,<7.1.0 # Apache-2.0
|
||||
|
||||
coverage!=4.4,>=4.0 # Apache-2.0
|
||||
oslo.config>=5.2.0 # Apache-2.0
|
||||
testrepository>=0.0.18 # Apache-2.0/BSD
|
||||
stestr>=2.0.0 # Apache-2.0
|
||||
testtools>=2.2.0 # MIT
|
||||
sphinx>=2.0.0,!=2.1.0 # BSD
|
||||
pylint>=2.6.0 # GPLv2
|
||||
|
||||
|
@@ -41,8 +41,8 @@ class InstallVenv(object):
|
||||
sys.exit(1)
|
||||
|
||||
def check_python_version(self):
|
||||
if sys.version_info < (2, 6):
|
||||
self.die("Need Python Version >= 2.6")
|
||||
if sys.version_info[0] < 3:
|
||||
raise Exception("Need Python Version 3")
|
||||
|
||||
def run_command_with_code(self, cmd, redirect_output=True,
|
||||
check_exit_code=True):
|
||||
@@ -158,6 +158,6 @@ class Fedora(Distro):
|
||||
return
|
||||
|
||||
if not self.check_pkg('python-virtualenv'):
|
||||
self.die("Please install 'python-virtualenv'.")
|
||||
self.die("Please install 'python3-virtualenv'.")
|
||||
|
||||
super(Fedora, self).install_virtualenv()
|
||||
|
23
tox.ini
23
tox.ini
@@ -1,10 +1,10 @@
|
||||
[tox]
|
||||
envlist = py39,py311,py312,pep8,pylint,docs
|
||||
minversion = 2.0
|
||||
skipsdist = True
|
||||
minversion = 4.0
|
||||
envlist = py3,py311,py312,pep8,docs,pylint,cover
|
||||
ignore_basepython_conflict = True
|
||||
|
||||
[testenv]
|
||||
basepython = python3
|
||||
basepython = {env:TOX_PYTHON:python3}
|
||||
usedevelop = True
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
NOSE_WITH_OPENSTACK=1
|
||||
@@ -16,10 +16,7 @@ deps = -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/up
|
||||
-r{toxinidir}/requirements.txt
|
||||
-r{toxinidir}/test-requirements.txt
|
||||
commands =
|
||||
python manage.py test {posargs}
|
||||
|
||||
[testenv:py39]
|
||||
basepython = python3.9
|
||||
python3 manage.py test {posargs}
|
||||
|
||||
[testenv:py311]
|
||||
basepython = python3.11
|
||||
@@ -34,13 +31,21 @@ commands = flake8 {posargs}
|
||||
commands = {posargs}
|
||||
|
||||
[testenv:cover]
|
||||
commands = python setup.py test --coverage --testr-args={posargs}
|
||||
commands = python3 setup.py test --coverage --testr-args={posargs}
|
||||
|
||||
[testenv:docs]
|
||||
deps = -r{toxinidir}/doc/requirements.txt
|
||||
setenv = DJANGO_SETTINGS_MODULE=freezer_ui.test.settings
|
||||
commands = sphinx-build -W --keep-going -b html doc/source doc/build/html
|
||||
|
||||
[testenv:pdf-docs]
|
||||
deps = {[testenv:docs]deps}
|
||||
allowlist_externals =
|
||||
make
|
||||
commands =
|
||||
sphinx-build -j auto -W -b latex doc/source doc/build/pdf
|
||||
make -C doc/build/pdf
|
||||
|
||||
[testenv:pylint]
|
||||
commands = pylint --rcfile .pylintrc freezer_ui
|
||||
|
||||
|
Reference in New Issue
Block a user