How to customise the "contact an administrator" message shown in the access denied page in Bamboo
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
This document talks about how you can change/customise the message that is displayed in the UI when a non-admin user in Bamboo tries to access some plan which they don't have access to. The current message asks users to contact their Bamboo administrators, which might result in a lot of emails sent to Bamboo administrators and a bit of confusion as to who is in charge of managing permissions for a certain project and plan. You might want to change that message to suggest another approach e.g. rather than contact a Bamboo administrator, contact a project administrator instead
Environment
Bamboo 8.0.5
Solution
The contact an administrator message that is displayed in the UI can be customized. To take an example, if you want to customise the message from contact an administrator to contact project administrator, you can follow the below steps:
- Based on your version of Bamboo, navigate to <bamboo-install>/atlassian-bamboo/WEB-INF/lib and locate the file atlassian-bamboo-language-8.0.5.jar.
- You should be able to simply open this jar file by using vim atlassian-bamboo-language-8.0.5.jar.
Inside this file, select the com/atlassian/bamboo/ww2/BambooActionSupport.properties and press enter. You will need to edit the line you want for your custom message. So this will be the below:
error.accessDenied.message = Sorry, you have insufficient permissions to view the page. \ Please {0}contact an administrator{1} if you believe this is an error.
Edit the contact an administrator in the above to contact a project administrator. It should look like the below:
error.accessDenied.message = Sorry, you have insufficient permissions to view the page. \ Please {0}contact a project administrator{1} if you believe this is an error.
- Then save the changes, exit vim, and restart Bamboo to apply the changes.
- Ask the non-admin user to access some plan as that user (by putting the plan-key in the URL manually).