I've figured it out. There are two things necessary:
- Give the service a different name
- Specify a different port.
To do this, edit the installService.ps1 script. Locate the line where the first argument to procrun is added:
$arguments += "//IS//SDLWebCacheService"
... and modify it to be different to the cache service you already have running. e.g.:
$arguments += "//IS//SDLWebStagingCacheService"
Where ever this name is used, you'll also have to modify it, so at the bottom of the script where sc.exe is invoked, and also in the matching uninstall script.
Find the part of the script where ++StartParams is added to $arguments, and add the following line (of course you can choose your own port number):
$arguments += "++StartParams=localhost:2099"
I'd have preferred not to modify the script shipped by SDL, but that would only be possible if they parameterised these things, and I hope they will in a future version.
Edit: For completeness, and after further reflection, I suppose I should answer my bonus question about whether I should expect problems when attempting to share a CCS between staging and live. As far as I know, invalidation messages are purely on the basis of the item ID, so presumably publishing to staging or live would invalidate the cached item both on staging and live. So the downside would be that you'd get some unnecessary cache invalidation, and some extra load because of it. I suspect in practice, you may not even notice.