]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/community/recipes/default.rb
community: container definitions should not be world readable
[chef.git] / cookbooks / community / recipes / default.rb
index 89743de31c0fb7a7de419922633b6bd61b2ed693..08f316d689e4fe2fd72d950aa3d855d398fc9464 100644 (file)
 
 include_recipe "accounts"
 include_recipe "docker"
-include_recipe "geoipupdate"
 include_recipe "git"
 include_recipe "ssl"
 
 passwords = data_bag_item("community", "passwords")
 license_keys = data_bag_item("geoipupdate", "license-keys") unless kitchen?
 
+# Disable any default installed apache2 service. Web server is embedded within the discourse docker container
+service "apache2" do
+  action [:disable, :stop]
+end
+
 directory "/srv/community.openstreetmap.org" do
   owner "root"
   group "root"
@@ -54,7 +58,7 @@ template "/srv/community.openstreetmap.org/docker/containers/data.yml" do
   source "data.yml.erb"
   owner "root"
   group "root"
-  mode "644"
+  mode "640"
   variables :passwords => passwords
   notifies :run, "execute[discourse_container_data_rebuild]"
 end
@@ -63,7 +67,7 @@ template "/srv/community.openstreetmap.org/docker/containers/web_only.yml" do
   source "web_only.yml.erb"
   owner "root"
   group "root"
-  mode "644"
+  mode "640"
   variables :license_keys => license_keys, :passwords => passwords
   notifies :run, "execute[discourse_container_web_only_bootstrap]"
 end
@@ -72,7 +76,7 @@ template "/srv/community.openstreetmap.org/docker/containers/mail-receiver.yml"
   source "mail-receiver.yml.erb"
   owner "root"
   group "root"
-  mode "644"
+  mode "640"
   variables :passwords => passwords
   notifies :run, "execute[discourse_container_mail_receiver_rebuild]"
 end