]> git.openstreetmap.org Git - chef.git/commitdiff
Use backports for osm2pgsql on debian
authorPaul Norman <penorman@mac.com>
Wed, 4 Sep 2024 01:21:21 +0000 (18:21 -0700)
committerPaul Norman <penorman@mac.com>
Wed, 4 Sep 2024 01:21:21 +0000 (18:21 -0700)
cookbooks/tile/recipes/default.rb
test/integration/tile/inspec/osm2pgsql_spec.rb [new file with mode: 0644]

index 2ebcbf041376ac00102ff9fc43b4bb7cd1884477..4f067ee688b2d08f89a4aea98859101d36c0172c 100644 (file)
@@ -505,6 +505,13 @@ directory "/var/log/tile" do
   mode "755"
 end
 
   mode "755"
 end
 
+if platform?("debian")
+  apt_preference "osm2pgsql" do
+    pin "release o=Debian Backports"
+    pin_priority "600"
+  end
+end
+
 package %w[
   osm2pgsql
   osmium-tool
 package %w[
   osm2pgsql
   osmium-tool
diff --git a/test/integration/tile/inspec/osm2pgsql_spec.rb b/test/integration/tile/inspec/osm2pgsql_spec.rb
new file mode 100644 (file)
index 0000000..e5efe33
--- /dev/null
@@ -0,0 +1,4 @@
+describe package("osm2pgsql") do
+  it { should be_installed }
+  its("version") { should cmp >= "1.11.0" }
+end