The lightweight slack approved system for managing invites to an open slack community
Other slack auto-invite systems can cause issues by automatically allowing scammers/phishers/spammers to join your open slack community. Slackproval is an open source solution that gives the admins of the community power to moderate their incoming new users.
Environment Variables:
Required
SLACK_API_TOKEN
- Slack API token for authentication. Must be the legacy api token found hereSLACK_SUBDOMAIN
- Slack subdomain (ex: example
in https://example.slack.com)DATABASE_URL
- Set the url for the database (default: localhost)
SLACK_NAME
Name of your slackSLACK_ICON
URL to your slack iconDEFAULT_ADMIN_EMAIL
- Email of the default admin, when they register they will automatically be given the admin roleADMIN_PASSWORD
- Password to get to the user sign up pageOptional
DATABASE_USER
- Set the user for the databaseDATABASE
- Name of the databaseDATABASE_PASSWORD
- Password to the database userDB_POOL
- Amount of database pool (default: 25)ADMIN_USERNAME
- Username to get to the user sign up page (default admin
)REQUIRE_REASON
- Whether or not your requesting users need to provide a reason for joining (default: true)CODE_OF_CONDUCT_REQUIRED
- Whether or not you mandate the requesting user agrees to a code of conduct (set to true
for yes)CODE_OF_CONDUCT_LINK
- Link to a markdown file containing your code of conduct. (EX: https://raw.githubusercontent.com/hash-gaming/code-of-conduct/master/code-of-conduct.md)USE_RECAPTCHA
- Whether to use Recaptcha v2 in the request flow to prevent bots; defaults to false.RECAPTCHA_SITE_KEY
- Required only if USE_RECAPTCHA
is set to trueRECAPTCHA_SECRET_KEY
- Required only if USE_RECAPTCHA
is set to trueAGE_MUST_BE_OVER_REQUIRED
- Whether or not you mandate the requesting user is over a certain age (set to true
for yes)AGE
- Configure the age for the AGE_MUST_BE_OVER_REQUIRED
check (default 18
)Notes
USE_RECAPTCHA
is set to true then RECAPTCHA_SITE_KEY
and RECAPTCHA_SECRET_KEY
also need to be set. You can set up a Recaptcha project here.ADMIN_USERNAME
and ADMIN_PASSWORD
and sign up with your DEFAULT_ADMIN_EMAIL
New
tab contains all requests that haven't received a responseApproved
tab contains all requests that have been approvedDenied
tab contains all requests that have been denied
Admin
allows the user to show/edit/destroy any user on SlackprovalThe code of conduct must be written and the environment variable CODE_OF_CONDUCT_REQUIRED
must be set to true
in order to require users to agree to a code of conduct before requesting access
To configre the code of conduct, follow these steps:
CODE_OF_CONDUCT_REQUIRED
to true
and restart your web applicationEdit Code of Conduct
button.env
file with the above configurationbundle install
to install gemsrake db:create
to create the databaserake db:migrate
to run the rails migrationspuma
to start the rails server
MOCK_INVITE
- Environment Variable, set to true
to not actually send out slack email invitesHelpful:
rake fake:requests
- Generates 100 fake requestsLogo created by logomakr.com