#9830 Scripts needing rewrite due to new auth
Closed: Fixed 4 days ago by kevin. Opened 16 days ago by smooge.

Describe what you would like us to do:

Various scripts are assuming that getent passwd will list all users which it does not anymore. These need to be rewritten to work with new AAA


Cron apache@people02 /usr/local/bin/make-people-page.py
Inbox
A-Fed-IS-Stuff/Cleanup
(Cron Daemon) apache@fedoraproject.org

13:52 (9 minutes ago)

to apache
Traceback (most recent call last):
File "/usr/local/bin/make-people-page.py", line 139, in <module>
users_list = subprocess.check_output("getent passwd | sort | cut -d: -f1,6 | grep /home/fedora/", shell=True)
File "/usr/lib64/python2.7/subprocess.py", line 575, in check_output
raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command 'getent passwd | sort | cut -d: -f1,6 | grep /home/fedora/' returned non-zero exit status 1

When do you need this to be done by? (YYYY/MM/DD)



Metadata Update from @mohanboddu:
- Issue priority set to: Waiting on Assignee (was: Needs Review)
- Issue tagged with: authentication, dev, high-gain, high-trouble, ops

16 days ago

Lets also find any other scripts that needs to be updated.

Cron apache@people02 /usr/local/bin/make-people-page.py

I believe nphilipp is working on this one

Related PR: https://pagure.io/fedora-infra/ansible/pull-request/531

It still fails with a Permission Error where it does a chown. I'm not sure what the aim of this chown is, ideas welcome :)

The make-people-page script has been adjusted with the PR above.

It now shows:

'anouar' is not owned by a named user. Skipping.
'eitch' is not owned by a named user. Skipping.
'fishter' is not owned by a named user. Skipping.
'flpw' is not owned by a named user. Skipping.
'gcintra' is not owned by a named user. Skipping.
'ifelix' is not owned by a named user. Skipping.
'kevmif' is not owned by a named user. Skipping.
'key' is not owned by a named user. Skipping.
'landocalrizzian' is not owned by a named user. Skipping.
'leandro' is not owned by a named user. Skipping.
'llosi' is not owned by a named user. Skipping.
'muerte' is not owned by a named user. Skipping.
'myne' is not owned by a named user. Skipping.
'royong' is not owned by a named user. Skipping.
'sizemj' is not owned by a named user. Skipping.
'soko' is not owned by a named user. Skipping.
'sunjwvista' is not owned by a named user. Skipping.
'tchuang' is not owned by a named user. Skipping.
'thierry' is not owned by a named user. Skipping.
'xhuang' is not owned by a named user. Skipping.
'znapora' is not owned by a named user. Skipping.

And indeed:

# ls -lsd /home/fedora/thierry/
0 drwxr-xr-x. 3 101041 101041 70 Feb 19  2009 /home/fedora/thierry/
# ls -lsd /home/fedora/soko/
0 drwxr-xr-x. 3 100880 100880 70 Mar 11  2009 /home/fedora/soko/
# ls -lsd /home/fedora/muerte/
0 drwxr-xr-x. 3 100881 100881 70 May 15  2008 /home/fedora/muerte/
# ls -lsd /home/fedora/key/
0 drwxr-xr-x. 3 102418 102418 83 Sep 28  2012 /home/fedora/key/
# ls -lsd /home/fedora/leandro/
0 drwxr-xr-x. 3 110470 110470 70 May 25  2011 /home/fedora/leandro/

I can see the leandro user in FAS and zodbot says the account is active. However, it doesn't seem that it was migrated.

@abompard could you confirm that these accounts were not migrated? Would you know why?

This boils down to: should we import these users or drop their homedirs on fedorapeople?

I discovered yesterday that some accounts were not migrated because their SSH key was the default "CHANGE ME" and the script choke on it. I'll do a pass to import them.

There were 422 of them... All imported now. I checked the user list in the ticket above and those are all in too.

There were 422 of them... All imported now. I checked the user list in the ticket above and those are all in too.

Thanks!

This should all be done now and working (as far as I can tell).

Metadata Update from @kevin:
- Issue close_status updated to: Fixed
- Issue status updated to: Closed (was: Open)

4 days ago

Login to comment on this ticket.

Metadata
Boards 2
dev Status: Backlog
ops Status: Backlog