Commit Graph

36 Commits

Author SHA1 Message Date
Zuul 9698321920 Merge "support for Masakari VMoves" 2024-03-06 09:06:39 +00:00
suzhengwei a75c6018ba support for Masakari VMoves
It supports for Masakari VMove API in microversion 1.3.

Change-Id: Iafc9da3037c858a327b8805c137c6a074c56d7cc
2024-02-28 09:35:44 +08:00
Zuul 3c275efa39 Merge "Fix auth_url to request.user.endpoint" 2024-02-20 02:59:27 +00:00
suzhengwei 91a51dfb12 support for Masakari VMove
It supports for Masakari VMove API in microversion 1.3.

Change-Id: Id06f4d1dd8a4e59760bd63f5f7df6a73319d6a9c
2024-01-25 09:54:25 +08:00
Vadym Markov eb4d103c3f Django 4.x: fix some import error
* ugettext_lazy is removed

In Django 3.0 ugettext_lazy/ungettext_lazy have been deprecated in favor
of gettext_lazy/ngettext_lazy [0].

* urlunquote is removed

In Django 3.0 django.utils.http.urlquote/urlquote_plus/urlunquote/urlunquote
have been deprecated in favor of the functions that they're aliases for:
urllib.parse.quote/quote_plus/unquote/unquote_plus [0].

We are now using Django 4.2, so we should update our code
with the gettext_lazy/ngettext_lazy aliases.

[0] https://docs.djangoproject.com/en/3.0/releases/3.0/#id3

Change-Id: I2fe090fe170dd832deb9cf454a0400303d2e3d92
2024-01-24 15:06:50 +08:00
chung00-lee 37de593d5b Fix auth_url to request.user.endpoint
The Horizon masakari-dashboard only connects to the public in the
openstack_connection() function (masakaridashboard/api/api.py).

Closes-Bug: #2035571

Change-Id: I15433029ee9775fb593937f34c287a66125a1aab
2023-09-17 01:05:31 +09:00
suzhengwei cb7ae677a6 remove duplicated code
Change-Id: Ie4380f034c7738a3fd0dd190960331aa1dc5f235
2023-08-02 15:27:05 +08:00
manchandavishal 6b6f058241 Address RemovedInDjango40Warning
In Django 3.1, django.conf.urls.url() is deprecated
in favor of django.urls.re_path(). For more info see [1]
These were already replaced in Horizon repo by [2].

[1] https://docs.djangoproject.com/en/4.0/releases/3.1/#id2
[2] https://review.opendev.org/c/openstack/horizon/+/827093

Change-Id: I4fe0d9520ad1cb4280a4f8df16fe7ee742ea420a
2022-04-29 17:57:02 +05:30
Pavlo Shchelokovskyy 021d1c184e Use service list instead of hypervisor list
the host names in them are not necessarily the same,
and Masakari service itself validates the input against
the nova service list, not hypervisor list,
since change I9c591d33f17a8d5950bdb1fc2d686e2301fc6d95 in Masakari.

Closes-Bug: #1944679
Change-Id: Id017b91c59aff54435c35d410fcb56a086a732ef
2021-09-23 14:43:39 +00:00
Vadym Markov 39f03063c0 Update policy file to yaml
See the included reno file for details.

Change-Id: I39834214740b2a494105a1130964fba3134d420c
2021-08-07 09:26:23 +00:00
Takashi Natsume b53745791b Replace getargspec with getfullargspec
inspect.getargspec() is deprecated since py3

[1] https://docs.python.org/3/library/inspect.html#inspect.getargspec

Signed-off-by: Takashi Natsume <takanattie@gmail.com>
Change-Id: I6670f1ad889204a29b6f37803e4da2d1efe6ef8e
2021-05-13 21:42:57 +09:00
Zuul a44b5a4266 Merge "Drop dep on python-masakariclient" 2021-03-25 16:59:19 +00:00
Radosław Piliszek fce116082b Add 'is_enabled' attr to segment
Implements: blueprint enable-to-segment
Change-Id: I378d98cc17afbfa9e56deb79ae479117dd231a7b
2021-03-24 08:58:40 +00:00
Radosław Piliszek f4640692b1 Drop dep on python-masakariclient
There is no logic in python-masakariclient that masakari-dashboard
requires. It is safe to drop. The check for supported API versions
was irrelevant already as it depends directly on OpenStack SDK.

Change-Id: I97c6db49f1a4dbd36f7003299938a05994e37cb6
2021-03-17 14:47:28 +00:00
Pavlo Shchelokovskyy 1a6d07c683 Disable dashboard when Masakari is not available
Change-Id: I59d91249fe4b2036c12ecca089a61937571be201
2021-02-25 13:08:01 +00:00
Zuul 7e7cd03fb1 Merge "Fix CA file for API client" 2020-09-23 08:59:49 +00:00
Mark Goddard 59ee1d59a1 Fix CA file for API client
If a custom CA file is configured via OPENSTACK_SSL_CACERT, currently
communication with Keystone will fail, since the session is not created
using this CA file.

This change fixes the issue by passing the path to the CA file to the
keystoneauth session constructor.

Change-Id: Iad1bdea97ed649cc3c8f042dc5dd147b989dfd0e
Closes-Bug: #1873736
2020-09-04 14:57:43 +00:00
manchandavishal 65b6d5a7af Cleanup for Refactor-error-messages
This patch is a clean-up patch for refactor-error-messages bp
which remove the exception message from base message otherwise
the same exception message display twice like
this https://ibb.co/XyFWMdz .

Change-Id: I7f569c39d9b39c81c5e7db61d499ce4192ad0bb7
Depends-On: https://review.opendev.org/708069
2020-09-04 07:24:44 +00:00
Michiel Piscaer 1dde9dc923 Add OPENSTACK_ENDPOINT_TYPE to the connection
Pass interface to honor 'OPENSTACK_ENDPOINT_TYPE' so it can have multiple endpoints,
without this it only communicate with the public endpoint.

Closes-Bug: #1891230
Change-Id: I7caf9170d63eff388af5d690dd6b054188752381
2020-08-12 21:41:18 +02:00
jacky06 31fe6d7544 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

Change-Id: Ib80f2494f0355f6eafcd1df7f7822e31e9e64c40
2020-05-15 17:24:25 +00:00
Sean McGinnis 7f5336cd0d
Use unittest.mock instead of third party mock
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.

Change-Id: I7bf6d007ca8c01b53152301d862f3aacf11480b2
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-20 16:08:32 -05:00
Ivan Kolodyazhny a64e5cafef s/assertItemsEqual/assertCountEqual/g
assertItemsEqual was renamed to assertCountEqual in Python 3, and the
testsuite is failing now - rename it.
See also https://six.readthedocs.io/#six.assertCountEqual

This unbreaks the testsuite.

Change-Id: I3cce625c3cad6303f99198ba1c91f59f6f5add41
2020-01-20 18:55:47 +02:00
niraj singh e05a1822db Implement real time data for recovery workflow details
Implemented real time data for notification recovery workflow details.

Change-Id: I8d8c909b0844af54c492fe046892e9e188d5460a
2019-03-13 08:22:02 +00:00
niraj singh 58989c3f41 Render progress details for notification
Added a new tab "Progress Details" on notification details page
to display status of the notification.

Depends-On: I9ba787bc8ef9528a7cff5b4c1411dffa454b66d2
Change-Id: I9807bfe3c61f455bf4d34d9da49b0f4945ca9d5a
2019-03-11 13:22:24 +00:00
Akihiro Motoki 4052bde700 Django 2.0 support
Horizon and most horizon plugins support Django 2.0 in Rocky.
This commit focuses on passing the unit tests with Django 2.0.
It would be nice if masakari-dashboard team tests it in
real environments.

Replace django.core.urlresolves with django.urls

(In Django 2.0) The django.core.urlresolvers module is removed
in favor of its new location, django.urls.
It was deprecated in Django 1.10:
https://docs.djangoproject.com/en/2.0/releases/1.10/#id3

Drops older Django unit tests from tox.ini
as horizon dropped Django <=1.10 support in Rocky.

Change-Id: I67907a2460f8472e5a6222210d74b3eed71be064
2018-09-30 20:10:29 +09:00
nitesh.vanarase 5ce36facc5 Fix incorrect message for host update
For host update it is showing incorrect message as "Successfully
updated segment". Modified the message as "Successfully updated
host".

Change-Id: Ib0c323a2b16b67ca73d0a0e5333ae69800e0203d
2018-08-07 12:07:52 +05:30
nirajsingh f53bdbb031 Added notification panel
Implemented notification list.

Implements: blueprint masakari-dashboard

Change-Id: I9a2558025fe3e49632016ce69b426aefb4975b51
2018-07-27 10:15:55 +00:00
nirajsingh f463ab19f8 Implement update host
Implemented update host functionality.
Also added test case for update host.

Partial-Implements: blueprint masakari-dashboard

Change-Id: I197440d069a1b5b49a234da8f05a01d45f222f2e
2018-07-26 08:40:43 +00:00
nirajsingh bef761d1d9 Implement host detail
Implemented host detail functionality.
Also Added test case for host detail.

Partial-Implements: blueprint masakari-dashboard

Change-Id: I7e62e4a2b1e15ddeb2a592670518d8358f4a6b1c
2018-07-26 08:38:47 +00:00
nirajsingh 9ae3efef6b Implement delete host
Implemented delete host functionality.
Also added test case for delete host.

Partial-Implements: blueprint masakari-dashboard

Change-Id: I8265b4f1af7bb61d15d005ee3785895f678f7d10
2018-07-26 08:38:18 +00:00
nirajsingh a83abbd2b5 Add host panel
Added host panel and implemented add and list host functionality.
Also added test cases that actually not covering the line of code
but tested the add and list host functionally.

Partial-Implements: blueprint masakari-dashboard

Change-Id: I756ab397bd9c84a4520c4ed12a576832784ab41f
2018-07-25 06:32:33 +00:00
nirajsingh b18ad52f0e Implement update segment
Added update segment functionality.
Also added test cases that actually not covering
the line of code but tested the update segment functionally.

Partial-Implements: blueprint masakari-dashboard

Change-Id: Ib0424ee076ff0e8cc8c3ea898d986d32cc195ed2
2018-07-12 11:07:35 +00:00
nirajsingh 4996c377ad Implement segment detail tab
Implemented segment detail functionality.
Added test cases that actually not covering the line of code
but tested the detail segment functionally.

Partial-Implements: blueprint masakari-dashboard

Change-Id: I214c9df87af3c4ff29abc2e2b30b287b81cd603c
2018-07-12 11:07:02 +00:00
nirajsingh 30d318803f Implement delete segment
Added delete segment functionality.
Also added test cases that actually not covering
the line of code but tested the delete segment functionally.

Partial-Implements: blueprint masakari-dashboard

Change-Id: Iabf59e92be9de09d2d2fde48fea403b7cd2bcd26
2018-07-12 11:04:17 +00:00
nirajsingh c429554def Add segment panel
Added segment panel and implemented list and create segment
functionality.Added test cases that actually not covering the
line of code but tested the list and create functionally.

Partial-Implements: blueprint masakari-dashboard

Change-Id: I1366bfdc188f4e0d53fa46f2a6ea3790c9f295fc
2018-07-05 12:34:31 +05:30
nirajsingh b09b094a2b Initial UI-Cookiecutter commit
Added required project files to the repository.

Change-Id: I869b9f2cf04ec00d8bbf00e2720e64175e55eaee
2018-03-16 10:02:55 +05:30