https://github.com/aherrmann/nixops-deamon-test
Simple Daemon on NixOS
https://github.com/aherrmann/nixops-deamon-test
Last synced: about 1 year ago
JSON representation
Simple Daemon on NixOS
- Host: GitHub
- URL: https://github.com/aherrmann/nixops-deamon-test
- Owner: aherrmann
- Created: 2014-07-22T20:37:18.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2014-07-22T20:37:34.000Z (almost 12 years ago)
- Last Synced: 2025-01-13T09:10:02.899Z (over 1 year ago)
- Language: Nix
- Size: 109 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Simple Daemon -- NixOps Test
Generates a VirtualBox machine that runs a very simple daemon process as a
NixOS service module.
That daemon repeatedly writes the current time and date into a file. A cron-job
will remove that file regularly.
## How to Deploy
Execute the following commands in order to create and deploy the machine.
nixops create machine.nix virtualbox.nix -d daemon
nixops deploy daemon
You can test that it works by executing the following commands
nixops ssh -d daemon runner
# Inside the VM
tail -F /var/mydaemon.out
After a while your terminal should look like this:
Tue Jul 22 22:34:53 CEST 2014
Tue Jul 22 22:34:58 CEST 2014
tail: ‘/var/mydaemon.out’ has become inaccessible: No such file or directory
Tue Jul 22 22:35:03 CEST 2014
Tue Jul 22 22:35:08 CEST 2014