Forum Discussion

KKumar's avatar
KKumar
New Contributor
11 years ago

Changing port for REST Mock Service

Hi,

I have to mockout a REST service but it runs on port 22015. I see that when creating mock REST services through SOAPUI, the port number is defaulted to 8080. Is there any possibility I can change it?

Thanks
Kanagha
  • nmrao's avatar
    nmrao
    Champion Level 3
    Click on the Mock Service Interface, look down for properties, change port number.
  • KKumar's avatar
    KKumar
    New Contributor
    The port field is not editable under properties section. Name, description and path can be modified though.

    Thanks
    kanagha
  • nmrao's avatar
    nmrao
    Champion Level 3
    Oh sorry I did not try modifying port number. Will have to see.
  • nmrao's avatar
    nmrao
    Champion Level 3
    See here, it allows.
  • AlekseiKlimkin's avatar
    AlekseiKlimkin
    Occasional Contributor

    Hi,

     

    Can I set the host and port values from inside a setup script in my mock service?

     

    I need to bring those values into a config file, but I am not sure as to how do I set these variables from script.

     

    What I know is that by starting the mock service from the command line I can manually change the port (http://blog.ashwani.co.in/blog/2013-01-10/soapui-mockservicerunner-on-linux-without-x-config/), but what I am interested in is setting host and port from inside a setup script.

     

    P.s. I am not sure that it is possible, but if it's not, then could I change the host the way it is done for port? (from the command line)