Commit 3aa773ad authored by Rocky Automation's avatar Rocky Automation 📺
Browse files

import rhc-0.2.0-1.el8_4

parent 2c1df9a5
SOURCES/rhc-0.1.4.tar.gz
SOURCES/rhc-0.2.0.tar.gz
1b3dd641970425837accba3f6981eef5f46b3376 SOURCES/rhc-0.1.4.tar.gz
8f9f437c9d7ee2afe09b2000aa77fd384fc91d2f SOURCES/rhc-0.2.0.tar.gz
From 31db6e5a21afb62183ea6721fd79d515fc9b77b9 Mon Sep 17 00:00:00 2001
From: Link Dupont <link@sub-pop.net>
Date: Wed, 30 Jun 2021 12:36:17 -0400
Subject: [PATCH 1/2] fix: Improve output during 'disconnect'
Now print the status of the disconnection process, including the results afterwards.
Fixes ESSNTL-837
Signed-off-by: Link Dupont <link@sub-pop.net>
---
cmd/ygg/main.go | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/cmd/ygg/main.go b/cmd/ygg/main.go
index 5226bce..f5c5c47 100644
--- a/cmd/ygg/main.go
+++ b/cmd/ygg/main.go
@@ -162,17 +162,21 @@ func main() {
fmt.Printf("Disconnecting %v from %v.\nThis might take a few seconds.\n\n", hostname, yggdrasil.Provider)
s := spinner.New(spinner.CharSets[9], 100*time.Millisecond)
- defer s.Stop()
- s.Suffix = " Disconnecting..."
+ s.Suffix = fmt.Sprintf(" Deactivating the %v daemon", yggdrasil.BrandName)
s.Start()
if err := deactivate(); err != nil {
return cli.Exit(err, 1)
}
+ s.Stop()
+ fmt.Printf(failPrefix+" Deactivated the %v daemon\n", yggdrasil.BrandName)
+ s.Suffix = " Disconnecting from Red Hat Subscription Management..."
+ s.Start()
if err := unregister(); err != nil {
return cli.Exit(err, 1)
}
s.Stop()
+ fmt.Printf(failPrefix + " Disconnected from Red Hat Subscription Management\n")
fmt.Printf("\nManage your Red Hat connector systems: https://red.ht/connector\n")
--
2.31.1
From 1d2d42276b6acc8cba062da9536e8acae69034be Mon Sep 17 00:00:00 2001
From: Link Dupont <link@sub-pop.net>
Date: Wed, 30 Jun 2021 14:47:00 -0400
Subject: [PATCH 2/2] feat: Include Description in help output
Fixes ESSNTL-838
Signed-off-by: Link Dupont <link@sub-pop.net>
---
cmd/ygg/main.go | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/cmd/ygg/main.go b/cmd/ygg/main.go
index f5c5c47..5524347 100644
--- a/cmd/ygg/main.go
+++ b/cmd/ygg/main.go
@@ -28,6 +28,14 @@ func main() {
app.Name = yggdrasil.ShortName
app.Version = yggdrasil.Version
app.Usage = "control the system's connection to " + yggdrasil.Provider
+ app.Description = "The " + app.Name + " command controls the system's connection to " + yggdrasil.Provider + ".\n\n" +
+ "To connect the system using an activation key:\n" +
+ "\t" + app.Name + " connect --organization ID --activation-key KEY\n\n" +
+ "To connect the system using a username and password:\n" +
+ "\t" + app.Name + " connect --username USERNAME --password PASSWORD\n\n" +
+ "To disconnect the system:\n" +
+ "\t" + app.Name + " disconnect\n\n" +
+ "Run '" + app.Name + " command --help' for more details."
log.SetFlags(0)
log.SetPrefix("")
--
2.31.1
%define debug_package %{nil}
Name: rhc
Version: 0.1.4
Version: 0.2.0
Release: 1%{?dist}
Epoch: 1
Summary: Message dispatch agent for cloud-connected systems
......@@ -11,6 +11,10 @@ URL: https://github.com/redhatinsights/yggdrasil
Source0: %{name}-%{version}.tar.gz
Source1: config.toml
# Fixed upstream
Patch0: 0001-fix-Improve-output-during-disconnect.patch
Patch1: 0002-feat-Include-Description-in-help-output.patch
ExclusiveArch: %{go_arches}
BuildRequires: git
......@@ -24,7 +28,7 @@ BuildRequires: systemd-devel
a receiving queue for instructions to be sent to the system via a broker.
%prep
%autosetup
%autosetup -p1
%build
......@@ -37,7 +41,8 @@ make PREFIX=%{_prefix} \
'BRANDNAME=Red Hat connector' \
TOPICPREFIX=redhat/insights \
VERSION=%{version} \
DATAHOST=cert.cloud.redhat.com
DATAHOST=cert.cloud.redhat.com \
'PROVIDER=Red Hat'
%install
......@@ -52,6 +57,7 @@ make PREFIX=%{_prefix} \
TOPICPREFIX=redhat/insights \
VERSION=%{version} \
DATAHOST=cert.cloud.redhat.com \
'PROVIDER=Red Hat' \
install
%{__install} -m 644 %{SOURCE1} %{buildroot}%{_sysconfdir}/%{name}/
......@@ -60,7 +66,7 @@ make PREFIX=%{_prefix} \
%doc README.md
%{_bindir}/%{name}
%{_sbindir}/%{name}d
%{_sysconfdir}/%{name}/config.toml
%config(noreplace) %{_sysconfdir}/%{name}/config.toml
%{_unitdir}/%{name}d.service
%{_datadir}/bash-completion/completions/*
%{_mandir}/man1/*
......@@ -69,6 +75,11 @@ make PREFIX=%{_prefix} \
%changelog
* Mon Aug 23 2021 Link Dupont <link@redhat.com> - 0.2.0-1
- New upstream release
- Mark config file as a noreplace config file
- Add two patches that fix some UX issues
* Fri Apr 9 2021 Link Dupont <link@redhat.com> - 0.1.4-1
- New upstream release
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment