diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2023-09-29 23:00:15 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2023-09-29 23:00:15 +0200 |
commit | b785f1d23b4f68716bc041a863a2ffd925f33ded (patch) | |
tree | 7242e8f05b2c0b4c360ac738644cf9b92380e916 | |
parent | Replace list of tex packages with texlive group. (diff) | |
download | profiles-b785f1d23b4f68716bc041a863a2ffd925f33ded.tar.gz profiles-b785f1d23b4f68716bc041a863a2ffd925f33ded.tar.xz |
Add redshift.
-rw-r--r-- | files/redshift.service | 13 | ||||
-rw-r--r-- | manifests/redshift.pp | 18 |
2 files changed, 31 insertions, 0 deletions
diff --git a/files/redshift.service b/files/redshift.service new file mode 100644 index 0000000..962eba3 --- /dev/null +++ b/files/redshift.service @@ -0,0 +1,13 @@ +[Unit] +Description=Redshift display colour temperature adjustment +Documentation=http://jonls.dk/redshift/ +After=display-manager.service + +[Service] +ExecStart=/usr/bin/redshift +Restart=always +Environment=FLAGS= +EnvironmentFile=/etc/default/redshift $FLAGS + +[Install] +WantedBy=default.target diff --git a/manifests/redshift.pp b/manifests/redshift.pp new file mode 100644 index 0000000..c2137c7 --- /dev/null +++ b/manifests/redshift.pp @@ -0,0 +1,18 @@ +# @summary Configures redshift +class profiles::redshift { + + ensure_packages(['redshift']) + + file { '/etc/systemd/user/redshift.service': + source => "puppet:///modules/${module_name}/redshift.service", + } + + $flags = @(EOF) + FLAGS=-l 58.411291:15.566336 + | EOF + + file { '/etc/default/redshift': + content => $flags, + replace => false, + } +} |