This plugin allows you to integrate Sauce OnDemand to Hudson. Specifically, you can:
After installing a plugin, specify your Sauce OnDemand access credential in the system configuration page as follows:
Once this is set, on each job configuration page, you can tell Hudson to set up an SSH tunnel for the duration of the build. In the following screenshot, before your build starts Hudson will set up a remote-to-local SSH tunnel, so that Seleinum running in the cloud can talk to the test locally running on port 8080 as "example.org:80". For more details about the concept of SSH tunnel in the context of Sauce OnDemand, see the documentation.
In the above example, "example.org" was hard-coded. In many situations, however, it is a bad idea to hard-code host names to tests like this, because it prevents multiple people from running the same tests at the same time, because Sauce OnDemand (naturally) doesn't allow you to define the same host name (like "example.org") to be used in multiple tunnel definitions.
So if two people in the team just so happen to run the same test, or more importantly in our context, if you have two Hudson jobs that perhaps build different branches of the same codebase, or if you have enabled concurrent builds of the job, then you will encounter this limitation.
To address this problem, Hudson Sauce OnDemand plugin is capable of auto-allocating an unique host name for each build. To do this, specify "AUTO" as the domain name. This will cause Hudson to create a unique host name, set up a tunnel under that host name, and make that host name available to your build as the environment variable SAUCE_ONDEMAND_HOST.
Your test execution will need to look for this value when connecting to Selenium.