Bug 28493 - Make koha-passwd display the username
Summary: Make koha-passwd display the username
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Packaging (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Mason James
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-06-01 08:09 UTC by Magnus Enger
Modified: 2023-12-28 20:47 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00,23.05.03,22.11.09,22.05.16
Circulation function:


Attachments
Bug 28493: Make koha-passwd display the username (1.28 KB, patch)
2022-09-21 11:47 UTC, Mason James
Details | Diff | Splinter Review
Bug 28493: Make koha-passwd display the username (1.29 KB, patch)
2022-09-21 11:50 UTC, Mason James
Details | Diff | Splinter Review
Bug 28493: Make koha-passwd display the username (1.29 KB, patch)
2022-09-21 12:46 UTC, David Nind
Details | Diff | Splinter Review
Bug 28493: Make koha-passwd display the username (1.37 KB, patch)
2023-07-19 12:16 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Magnus Enger 2021-06-01 08:09:05 UTC
The current output looks like this:

sudo koha-passwd <site>
Password for <site>: abc123
Press enter to clear the screen...

But who remembers what the username looks like? It would be helpful to print this too, along with the password. 

(The format of the username is "koha_<site>".)
Comment 2 Mason James 2022-09-21 11:50:19 UTC
Created attachment 140814 [details] [review]
Bug 28493: Make koha-passwd display the username

to test...

1/ run command
 $ sudo koha-passwd dev1
 Password for dev1: CraZyPa$$WoRD!!
 Press enter to clear the screen...
 ^C

2/ apply patch

3/ run command again, note 'username' section
 $ sudo koha-passwd dev1
 Username for dev1: koha_dev1  <<<<<<<<<<<<
 Password for dev1: CraZyPa$$WoRD!!
 Press enter to clear the screen...
 ^C
Comment 3 David Nind 2022-09-21 12:46:50 UTC
Created attachment 140816 [details] [review]
Bug 28493: Make koha-passwd display the username

to test...

1/ run command
 $ sudo koha-passwd dev1
 Password for dev1: CraZyPa$$WoRD!!
 Press enter to clear the screen...
 ^C

2/ apply patch

3/ run command again, note 'username' section
 $ sudo koha-passwd dev1
 Username for dev1: koha_dev1  <<<<<<<<<<<<
 Password for dev1: CraZyPa$$WoRD!!
 Press enter to clear the screen...
 ^C

Signed-off-by: David Nind <david@davidnind.com>
Comment 4 David Nind 2022-09-21 12:49:05 UTC
Testing notes (using KTD):

- dev1 = instance name (default for KTD = kohadev)

- Had to shut down KTD and restart for the change to appear (flush_memcached, restart_all wasn't enough)
Comment 5 Katrin Fischer 2023-07-01 09:55:36 UTC
I don't see why this was moved to ASSIGNED after having been signed off - Magnus, could you check?
Comment 6 Magnus Enger 2023-07-03 06:27:23 UTC
(In reply to Katrin Fischer from comment #5)
> I don't see why this was moved to ASSIGNED after having been signed off -
> Magnus, could you check?

Dunno, setting it back to signed off.
Comment 7 Jonathan Druart 2023-07-19 12:16:42 UTC
Created attachment 153647 [details] [review]
Bug 28493: Make koha-passwd display the username

to test...

1/ run command
 $ sudo koha-passwd dev1
 Password for dev1: CraZyPa$$WoRD!!
 Press enter to clear the screen...
 ^C

2/ apply patch

3/ run command again, note 'username' section
 $ sudo koha-passwd dev1
 Username for dev1: koha_dev1  <<<<<<<<<<<<
 Password for dev1: CraZyPa$$WoRD!!
 Press enter to clear the screen...
 ^C

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 8 Tomás Cohen Arazi (tcohen) 2023-07-19 16:00:03 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 9 Fridolin Somers 2023-08-04 01:47:20 UTC
Small enhancement,
Pushed to 23.05.x for 23.05.03
Comment 10 Pedro Amorim 2023-08-18 10:53:25 UTC
Nice work everyone!

Pushed to 22.11.x for next release
Comment 11 Lucas Gass (lukeg) 2023-09-13 21:00:45 UTC
Backported to 22.05.x for upcoming 22.05.16