Skip to content

webui: re-add show update status for clients#1371

Merged
arogge merged 3 commits intobareos:masterfrom
joergsteffens:dev/joergs/master/webui-show-update-status
Jun 7, 2023
Merged

webui: re-add show update status for clients#1371
arogge merged 3 commits intobareos:masterfrom
joergsteffens:dev/joergs/master/webui-show-update-status

Conversation

@joergsteffens
Copy link
Member

@joergsteffens joergsteffens commented Feb 6, 2023

Displaying the client update status in the webui has been broken for a while. PR #1365 removes the code. This PR re-adds a simplified version.

It is based on https://download.bareos.com/release-info/bareos-version-info.js?callback=jsonCallback. It contains a sorted list of Bareos versions together with further information.

jsonCallback(
[
  {
    "version": "22.0.3",
    "status": "uptodate",
    "package_update_info": "Current Bareos release."
  },
  {
    "version": "22.0.0",
    "status": "update_required",
    "package_update_info": "Outdated Bareos packages. Please update to latest release."
  },
  {
    "version": "21.1.7",
    "status": "uptodate",
    "package_update_info": "Current Bareos release."
  },
  {
    "version": "21.0.0",
    "status": "update_required",
    "package_update_info": "Outdated Bareos packages. Please update to latest release."
  },
  {
    "version": "20.0.8",
    "status": "uptodate",
    "package_update_info": "Current Bareos release."
  },
  {
    "version": "20.0.0",
    "status": "update_required",
    "package_update_info": "Outdated Bareos packages. Please update to latest release."
  },
  {
    "version": "06.6.7",
    "status": "update_required",
    "package_update_info": "Outdated Bareos packages. Please update to latest release."
  },
  {
    "version": "06.6.6",
    "status": "update_required",
    "critical": true,
    "package_update_info": "Evil version. Update immediately."
  },
  {
    "version": "0.0.0",
    "status": "upgrade_required",
    "package_update_info": "Out of support. Please upgrade to a supported version."
  }
]
);

So it requires that the build process creates and updates this file on download.bareos.com.

Thank you for contributing to the Bareos Project!

Please check

  • Short description and the purpose of this PR is present above this paragraph
  • Your name is present in the AUTHORS file (optional)

If you have any questions or problems, please give a comment in the PR.

Helpful documentation and best practices

Checklist for the reviewer of the PR (will be processed by the Bareos team)

Make sure you check/merge the PR using devtools/pr-tool to have some simple automated checks run and a proper changelog record added.

General
  • Is the PR title usable as CHANGELOG entry?
  • Purpose of the PR is understood
  • Commit descriptions are understandable and well formatted
  • Check backport line
  • Is https://git.bareos.com/bareos/CD/pulls/57 merged?
Source code quality
  • Source code changes are understandable
  • Variable and function names are meaningful
  • Code comments are correct (logically and spelling)

OP#5394

@joergsteffens joergsteffens self-assigned this Feb 6, 2023
@bruno-at-bareos
Copy link
Contributor

bruno-at-bareos commented Feb 7, 2023

@joergsteffens actually the jsonCallback seems to be bugged

22.0.2 and 21.1.6 are the stable

jsonCallback(
{
  "/^22.0.1$/":{
    "status":"uptodate",
    "package_update_info":"Current Bareos 22 release."
  },
  "/^21.0.5$/":{
    "status":"uptodate",
    "package_update_info":"Current Bareos 21 release."
  },

@joergsteffens
Copy link
Member Author

As https://git.bareos.com/bareos/CD/pulls/57 isn't merged, the JSON file will not be updated. After this is merged, the JSON will correspond to the latest releases.

@joergsteffens joergsteffens force-pushed the dev/joergs/master/webui-show-update-status branch from f619b85 to 630f989 Compare April 6, 2023 16:51
@joergsteffens joergsteffens force-pushed the dev/joergs/master/webui-show-update-status branch 2 times, most recently from c07287b to 618af18 Compare April 9, 2023 17:29
@joergsteffens joergsteffens force-pushed the dev/joergs/master/webui-show-update-status branch 2 times, most recently from 369d961 to fb212c4 Compare April 17, 2023 18:02
@joergsteffens joergsteffens requested a review from frb121 April 17, 2023 21:11
@frb121 frb121 marked this pull request as ready for review April 18, 2023 09:31
@frb121 frb121 self-requested a review April 18, 2023 11:03
Copy link
Contributor

@frb121 frb121 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good. If you like squash my commit on top before merge.

@joergsteffens joergsteffens force-pushed the dev/joergs/master/webui-show-update-status branch 3 times, most recently from 6538e5b to bb450a7 Compare April 20, 2023 14:04
joergsteffens and others added 3 commits June 7, 2023 15:30
The server download.bareos.com offers a sorted list of current Bareos
releases at
https://download.bareos.com/release-info/bareos-version-info.js
The Bareos-WebUI uses this list and add status information about the
Bareos clients.
@arogge arogge force-pushed the dev/joergs/master/webui-show-update-status branch from dd9ba47 to 72dd31a Compare June 7, 2023 13:30
@arogge arogge merged commit 80099eb into bareos:master Jun 7, 2023
@joergsteffens joergsteffens deleted the dev/joergs/master/webui-show-update-status branch October 11, 2023 08:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants