Skip to content

Redirect people who end up at test.outreachy.org instead of www.outreachy.org #605

@sagesharp

Description

@sagesharp

Describe the bug

Outreachy deploys our website at a second subdomain test.outreachy.org. This website is used to test new features, or software updates, before pushing to the production Outreachy website www.outreachy.org.

In order to test new features, I often copy the production website's database to the test website's database. This means anyone who has an account on the production website can also log into the test website. However, the test website does not send emails (it prints the emails to the Django logs instead). This means people cannot activate new accounts on the test website.

Google and other search engines have indexed the test website. This means search results for Outreachy may link to the test website (especially for documentation) instead of the production website.

This means both applicants, coordinators, and mentors can log into the test website. They can do any action they would on the production website, including submitting initial applications, signing up a community to coordinate, or submitting internship projects. Then they get confused as to why they didn't receive a notice about their initial application, or why their community or project isn't showing up on the internship cohort's project list. Additionally, new applicants will try to create a new account, and never receive a confirmation email.

To Reproduce

Steps to reproduce the behavior:

  1. Go to the Outreachy test website login page
  2. Log into the test website, using your account information from the production website (ask Sage or others to copy the production database to the test database, if you recently created your account).
  3. If you can log in (and you are not an Outreachy organizer with the Django 'staff' permission set), then you have replicated the bug.
  4. Try to do things like create a new community, record a contribution, submit an initial application, or whatever actions are available during this phase of the Outreachy cohort. If you can do one of those things (and you are not an Outreachy organizer), you have replicated this bug.

Expected behavior

Outreachy's test website should not allow anyone but staff to log in. This should allow Outreachy organizers to test all the functionality of the website, since we can set ourselves as a community coordinator, mentor, or submit an application.

Outreachy's test website should have a warning banner if the subdomain it is deployed on is not 'www'. The warning banner should let people know this is Outreachy's test website, and encourage them to visit the production website again (providing a link for them to click, and a button that will redirect them, maybe something like 'Go to Outreachy website').

Outreachy's test website should not allow people to create new accounts. The create account page should throw an error on the account creation form, and tell people to go to the production website instead.

Outreachy's test website should have a robots.txt file that discourages all indexing. This robots.txt file should not show up on the production website.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions