Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,556,127
Community Members
 
Community Events
184
Community Groups

Customizing JIRA Look and Feel

Intro

At my job, we have a couple JIRA environments that we use in addition to our production environment. We use these other JIRA installs to test upgrades/updates to JIRA and to install and demo major changes and plugins.

We keep the look and feel of our production environment pretty much stock, so we needed a way to differentiate between our production environment and our other various JIRA installs. I've written some scripts that allow us to refresh these testing environments easily, so that we have current, relevant data pulled from our producton JIRA. Because these test installs can be so similar to our production JIRA after running the scripts, we needed a way to ensure that we are always aware which environment we are in.

Luckily, the JIRA REST API allows us to modify the look and feel of JIRA. And if we can schedule these API calls, in crontab for example, we can ensure that the look and feel for all of our environments are consistent all the time.

The Solution

Here is a sample of the script we placed in the crontab of our test environments, scheduled to run every minute, that updates the UI/text colors, as well as the main site title:

#!/bin/sh

##TESTING ENVIRONMENT

##Change UI Colors

##Header Background Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#003b48"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.lf.top.bgcolour
##Header Highlight Background Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#708090"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.lf.top.hilightcolour
##Header Separator Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#ffffff"}' -H "Content-Type: application/json" https://jira-staging.trifecta.com/rest/api/2/application-properties/jira.lf.top.separator.bgcolor
##Header Text Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#ffffff"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.lf.top.textcolour
##Menu Item Highlight Background Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#708090"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.lf.menu.bgcolour
##Menu Item Highlight Text Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#ffffff"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.lf.menu.textcolour
##Button Background Color
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "#c0c0c0"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.lf.hero.button.base.bg.colour
##Set Title
/usr/bin/curl -k -D- -u ADMINUSER:ADMINPASSWORD -X PUT --data '{"value" : "TESTING ENVIRONMENT"}' -H "Content-Type: application/json" https://TESTING.DOMAIN.COM/rest/api/2/application-properties/jira.title

1 comment

Hi @zack this works pretty good actually, but when I change the color over API its not applied automatically. Only when I restart jira, the color has changed also.
When I do it manually from "look and feel" however, there is "apply" button and when I apply, after refresh, it is changed, so there is no need to restart jira. 
Question:
Is there a way to do apply over API as well, so that I dont need to restart Jira?

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events