]> git.openstreetmap.org Git - chef.git/commitdiff
otrs: use apt_preference for otrs backport priority
authorGrant Slater <github@firefishy.com>
Wed, 1 May 2024 19:05:12 +0000 (20:05 +0100)
committerGrant Slater <github@firefishy.com>
Wed, 1 May 2024 19:33:31 +0000 (20:33 +0100)
cookbooks/otrs/recipes/debian.rb

index bed09a8b346e9c2e0a3995ccc93bcec57bd0e8d3..2d683b17e6d6ea38c3466f2dd8cb588224cb3710 100644 (file)
@@ -62,10 +62,14 @@ template "/etc/dbconfig-common/otrs2.conf" do
             :database_password => database_password
 end
 
-apt_package "otrs2" do
-  options "-t #{node[:lsb][:codename]}-backports"
+# Ensure the OTRS package in backports has a priority preference.
+apt_preference "otrs2" do
+  pin "release o=Debian Backports"
+  pin_priority "600"
 end
 
+apt_package "otrs2"
+
 # Ensure debconf is repopulated on a dbconfig change
 execute "dpkg-reconfigure-otrs2" do
   action :nothing