]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/mysql/recipes/default.rb
Add support for carto v4 to replication command
[chef.git] / cookbooks / mysql / recipes / default.rb
index 49087e67a1b78d7a2dacfb1f1377042d4438d1b2..427081239daa786675442735ee1adbdc881ae64d 100644 (file)
@@ -25,7 +25,13 @@ service "mysql" do
   supports :status => true, :restart => true
 end
 
-template "/etc/mysql/conf.d/chef.cnf" do
+conf_file = if node[:lsb][:release].to_f >= 16.04
+              "/etc/mysql/mysql.conf.d/zzz-chef.cnf"
+            else
+              "/etc/mysql/conf.d/zzz-chef.cnf"
+            end
+
+template conf_file do
   source "my.cnf.erb"
   owner "root"
   group "root"