CI / CD Settings are still accessible via URL even after Pipeline settings is disabled in General Settings

Summary

The "CD/CD Settings" should not be accessible after disabling the pipeline settings as per the How to enable or disable GitLab CI/CD

Steps to reproduce

  • Navigate to Settings > General > Visibility, project features, permissions.
  • Expand the Repository section
  • Disable the Pipelines toggle if already enabled
  • After saving changes, the CI/CD menu item on the left pane is hidden
  • Now navigate to the CI/CD project settings using the URL i.e. PROJECT_URL/-/settings/ci_cd
  • The CI/CD settings are still accessible which should not be the case.

Example Project

Yes this is reproducible on gitlab.com testproject-cicd-settings and has been raised by one of our customer in this Zen Desk ticket #153376

What is the current bug behavior?

The CI/CD settings are still accessible when navigating using the URL while Pipeline settings is disabled though it shows an error as shown in the screenshots attached.

What is the expected correct behavior?

One should not be able to access the CI/CD settings when the pipeline checkbox is disabled

Relevant logs and/or screenshots

Confirmation that the pipeline checkbox is disabled

Screenshot_2020-04-14_at_15.23.35

After navigating to the project settings using the URL e.g. PROJECT_URL/-/settings/ci_cd

Screenshot_2020-04-14_at_15.26.22

Possible fixes

Disable URL navigation to the CI/CD settings when the Pipeline settings is disabled.

Edited by Silvester Wainaina