Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Make sites-* files end in .conf to avoid conflicts with .md5 and othe…

…r files
  • Loading branch information...
commit 44bba81f2c2df50f2bf9b62a82140e49081bfeeb 1 parent 27b256c
@blakesmith authored
View
2  resources/crate/nginx/nginx.conf
@@ -29,5 +29,5 @@ http {
gzip_types ~(apply str (interpose " " gzip_types));
include /etc/nginx/conf.d/*.conf;
- include /etc/nginx/sites-enabled/*;
+ include /etc/nginx/sites-enabled/*.conf;
}
View
4 src/pallet/crate/nginx.clj
@@ -215,8 +215,8 @@
:locations -- locations (a seq of maps, with keys :location, :root
:index, :proxy_pass :passenger-enabled :rails-env)"
[session name & {:keys [locations action] :or {action :enable} :as options}]
- (let [available (format "%s/sites-available/%s" nginx-conf-dir name)
- enabled (format "%s/sites-enabled/%s" nginx-conf-dir name)
+ (let [available (format "%s/sites-available/%s.conf" nginx-conf-dir name)
+ enabled (format "%s/sites-enabled/%s.conf" nginx-conf-dir name)
site (fn [session filename]
(let [locations (string/join
\newline
View
4 test/pallet/crate/nginx_test.clj
@@ -16,10 +16,10 @@
(directory/directory "/etc/nginx/sites-available")
(directory/directory "/etc/nginx/sites-enabled")
(remote-file/remote-file
- "/etc/nginx/sites-enabled/mysite"
+ "/etc/nginx/sites-enabled/mysite.conf"
:content "server {\n listen 80;\n server_name localhost;\n\n access_log /var/log/nginx/access.log;\n\nlocation / {\n root /some/path;\n index index.html index.htm;\n \n \n \n}\n\nlocation /a {\n \n index index.html index.htm;\n proxy_pass localhost:8080;\n \n \n}\n\n}\n")
(file/file
- "/etc/nginx/sites-available/mysite" :action :delete :force true)))
+ "/etc/nginx/sites-available/mysite.conf" :action :delete :force true)))
(first
(build-actions/build-actions
{:server {:group-name :n :image {:os-family :ubuntu}}}
Please sign in to comment.
Something went wrong with that request. Please try again.