Skip to content

Commit

Permalink
Merge pull request #487 from tserong/wip-fix-a-couple-of-things
Browse files Browse the repository at this point in the history
Bump to v16.2.4, fix a couple of things

Reviewed-by: Michael Fritch <[email protected]>
Reviewed-by: Moritz Röhrich <[email protected]>
  • Loading branch information
tserong authored Dec 20, 2022
2 parents 500b4f3 + c6d31a8 commit 6193518
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on: [push, pull_request]
jobs:
build:

runs-on: ubuntu-latest
runs-on: ubuntu-20.04
strategy:
matrix:
py:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
pytest:
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
strategy:
matrix:
include:
Expand Down
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [16.2.4] - 2022-12-19
### Fixed
- Use daemon name rather than service type when stopping services
- Run `saltutil.sync_runners` in ceph-salt-formula %post script (#486)
- Don't explicitly install ceph-common (rely on ceph-base dependency)
- Support monochrome terminals in `ceph-salt apply`

## [16.2.3] - 2022-04-14
### Fixed
- Fix ceph-salt update when run prior to cluster deployment (#482)
Expand Down Expand Up @@ -335,7 +342,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Minimal README.
- The CHANGELOG file.

[Unreleased]: https://github.com/ceph/ceph-salt/compare/v16.2.3...HEAD
[Unreleased]: https://github.com/ceph/ceph-salt/compare/v16.2.4...HEAD
[16.2.4]: https://github.com/ceph/ceph-salt/releases/tag/v16.2.4
[16.2.3]: https://github.com/ceph/ceph-salt/releases/tag/v16.2.3
[16.2.2]: https://github.com/ceph/ceph-salt/releases/tag/v16.2.2
[16.2.1]: https://github.com/ceph/ceph-salt/releases/tag/v16.2.1
Expand Down
1 change: 0 additions & 1 deletion ceph-salt-formula/salt/ceph-salt/apply/cephtools.sls
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ install cephadm:
pkg.installed:
- pkgs:
- ceph-base
- ceph-common
- failhard: True
{{ macros.end_step('Install ceph packages') }}
Expand Down
6 changes: 5 additions & 1 deletion ceph-salt.spec
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
%endif

Name: ceph-salt
Version: 16.2.3
Version: 16.2.4
Release: 1%{?dist}
Summary: CLI tool to deploy Ceph clusters
License: MIT
Expand Down Expand Up @@ -124,6 +124,10 @@ Requires(pre): salt-master
Salt Formula to deploy Ceph clusters.


%post -n ceph-salt-formula
# This is needed in order for the network.iperf runner to work
salt-run --log-level warning saltutil.sync_runners || :

%files -n ceph-salt-formula
%defattr(-,root,root,-)
%license LICENSE
Expand Down
27 changes: 15 additions & 12 deletions ceph_salt/execute.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,21 +109,24 @@ def start(self):
self.body_height = self.height - self.HEADER_HEIGHT - self.FOOTER_HEIGHT
self.body_width = self.width - 1
logger.info("current terminal size: rows=%s cols=%s", self.height, self.width)
curses.start_color()
curses.use_default_colors()

curses.init_pair(self.COLOR_MARKER, -1, -1)
curses.init_pair(self.COLOR_MINION, curses.COLOR_CYAN, -1)
curses.init_pair(self.COLOR_STAGE, curses.COLOR_YELLOW, -1)
curses.init_pair(self.COLOR_STEP, curses.COLOR_BLUE, -1)
curses.init_pair(self.COLOR_MENU, curses.COLOR_BLACK, curses.COLOR_GREEN)
curses.init_pair(self.COLOR_SUCCESS, curses.COLOR_GREEN, -1)
curses.init_pair(self.COLOR_ERROR, curses.COLOR_RED, -1)
curses.init_pair(self.COLOR_WARNING, curses.COLOR_YELLOW, -1)
try:
curses.start_color()
curses.use_default_colors()
curses.init_pair(self.COLOR_MARKER, -1, -1)
curses.init_pair(self.COLOR_MINION, curses.COLOR_CYAN, -1)
curses.init_pair(self.COLOR_STAGE, curses.COLOR_YELLOW, -1)
curses.init_pair(self.COLOR_STEP, curses.COLOR_BLUE, -1)
curses.init_pair(self.COLOR_MENU, curses.COLOR_BLACK, curses.COLOR_GREEN)
curses.init_pair(self.COLOR_SUCCESS, curses.COLOR_GREEN, -1)
curses.init_pair(self.COLOR_ERROR, curses.COLOR_RED, -1)
curses.init_pair(self.COLOR_WARNING, curses.COLOR_YELLOW, -1)
curses.curs_set(0)
except Exception: # pylint: disable=broad-except
logger.warning("Unable to initialize curses color support (TERM=%s)",
os.environ.get('TERM', 'not set'))

curses.noecho()
curses.cbreak()
curses.curs_set(0)
self.stdscr.keypad(True)

if self.height > 2:
Expand Down

0 comments on commit 6193518

Please sign in to comment.