How to deal with spam posts on pagure

When an ticket is raised for a spam user on the Fedora infra tracker take the following actions.

Clear the spam

Click on the user in pagure and check their activity for all comments they have made. Remove all these comments unless otherwise advised.

Ban the user in pagure

ssh to pagure02.fedoraproject.org. As root user run the following command:

pagure-admin block-user <username> <date to block until>

For example:

pagure-admin block-user spamuser 2060-01-01

Remove all the content created by the spam user

Still on pagure02.fedoraproject.org. As root user run the following command:

pagure-admin sanitize-spam-user <spamer_username> <your_username>

For example:

pagure-admin sanitize-spam-user spamuser admin

Unwatch the projects watched by the user

If the spam is persistent even after blocking the user on the project you should remove the user from watchlist for the project.

pagure-admin update-watch namespace/project <username> -s 0
For now it’s not easy to find all the projects the user is watching.

Disable user in IPA

Frontend

  1. Login to the [ipa server](https://id.fedoraproject.org/ipa/ui) and search the users name.

  2. Click on the user.

  3. In the Actions dropdown menu click disable

Command line

  1. ssh to ipa01.iad2.fedoraproject.org

  2. run ipa user-disable <user>