I am trying to write a service definition for a slightly weird daemon that, in particular, insists on being told the system hostname via a file of its own, instead of reading it out of /etc/hostname or using gethostname. The logical way to deal with this is to make that special file be a symlink to one of /etc/hostname, /etc/static/hostname, or /gnu/store/xxxxxxxx-hostname (i.e. the store entry /etc/static/hostname points at). But I can't figure out how to do that. There doesn't seem to be an analogue of local-file or plain-file for symlinks, and I just spent half an hour poking at the guix repl trying to get the daemon to cough up /gnu/store/xxxxxxxx-hostname as a thing I could put into a gexp, without any luck.
How would you suggest that this be done? zw