[Nix-dev] systemd stdout logging

Richard Wallace rwallace at thewallacepack.net
Sun Jun 28 20:29:25 CEST 2015


No, I didn't disable anything. Originally I didn't have the standardoutput
lines either, expecting it to go to the journal.

This is especially frustrating because the way the app behaves when run
from systemd is different than when run from the command line on that same
instance and I can't figure out why. I was hoping the logs would provide
some idea of why.

I wonder if the two are related. Maybe I can send the logs to a file.
On Jun 28, 2015 3:08 AM, "Luca Bruno" <lethalman88 at gmail.com> wrote:

> Well it's weird, since even without that StandardOutput = "journal"; my
> services log to journalctl. You didn't disable journal storage or something
> like that, right?
>
> On Sun, Jun 28, 2015 at 7:48 AM, Richard Wallace <
> rwallace at thewallacepack.net> wrote:
>
>> I've got a service that I'm deploying with nixops. I've got a systemd
>> service configured
>>
>>      systemd.services.hiplambda = {
>>         description = "HipLambda";
>>         wantedBy = [ "multi-user.target" ];
>>         after = [ "network.target" ];
>>         requires = [ "postgresql.service" ];
>>         environment = {
>>           PORT = "8080";
>>           BASE_URI = baseurl;
>>           MUEVAL_TIMEOUT = "8";
>>           DATABASE_URL = "postgresql://localhost/hiplambda";
>>           PATH = "${ghc}/bin";
>>         };
>>         serviceConfig = {
>>           ExecStart = "${ghc}/bin/hiplambda";
>>           # For security reasons we'll run this process as a special
>> 'hiplambda' user
>>           User = "hiplambda";
>>           Restart = "always";
>>           StandardOutput = "journal";
>>           StandardError = "journal";
>>         };
>>       };
>>
>> The binary does it's logging to standard out and standard error, but
>> nothing is appearing in the journal. I haven't been able to find any other
>> logs. What am I missing?
>>
>> Thanks,
>> Rich
>>
>> _______________________________________________
>> nix-dev mailing list
>> nix-dev at lists.science.uu.nl
>> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>>
>>
>
>
> --
> NixOS Linux <http://nixos.org>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20150628/7c56298e/attachment.html 


More information about the nix-dev mailing list