How to get client ip and host address in jira when creating an issue

metinbulak August 1, 2019

I want to write groovy script to get client ip adress but no information found in google.

some code I found is :

HttpServletRequest request = ServletActionContext.getRequest();
String ipAddress = request.getRemoteAddr();

import java.net.InetAddress;
localhost = InetAddress.getLocalHost();
log.info "My local machine name | IP address is : " + localhost
log.info "Only IP Address : " + localhost.getHostAddress()

 

this code is not I am looking for

How to get client ip address in groovy script or plugin in jira?

 

 

0 answers

Suggest an answer

Log in or Sign up to answer