Skip to content

Commit 6f10c86

Browse files
author
Jamie Hanlon
committed
Update deployment configuration.
1 parent 37d3c6b commit 6f10c86

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ RUN apt-get update && \
77
apt-get install -y gitweb fcgiwrap
88

99
RUN ln -s /usr/share/gitweb /opt/www
10+
ADD gitweb.conf /etc/gitweb.conf
1011

11-
RUN rm -v /etc/nginx/nginx.conf
12+
RUN rm /etc/nginx/nginx.conf
1213
ADD nginx.conf /etc/nginx
13-
ADD gitweb.conf /etc/gitweb.conf
1414

1515
CMD spawn-fcgi -s /var/run/fcgiwrap.socket /usr/sbin/fcgiwrap && \
1616
nginx "-g" "daemon off;"

nginx.conf

+10-3
Original file line numberDiff line numberDiff line change
@@ -11,22 +11,29 @@ events {
1111
http {
1212
include /etc/nginx/mime.types;
1313
default_type application/octet-stream;
14+
#include /etc/nginx/fastcgi.conf;
1415
sendfile on;
1516
gzip off;
1617
keepalive_timeout 65;
1718

1819
server {
1920
listen 80;
2021
root /opt/www;
22+
charset utf-8;
2123
location / {
22-
fastcgi_pass unix:/var/run/fcgiwrap.socket;
24+
try_files $uri @gitweb;
25+
}
26+
location @gitweb {
2327
fastcgi_param SCRIPT_FILENAME /opt/www/gitweb.cgi;
2428
fastcgi_param PATH_INFO $uri;
2529
fastcgi_param GITWEB_CONFIG /etc/gitweb.conf;
2630
include fastcgi_params;
31+
fastcgi_pass unix:/var/run/fcgiwrap.socket;
32+
fastcgi_index gitweb.cgi;
2733
gzip off;
2834
}
29-
location /static {
30-
}
35+
#location /static {
36+
# root /opt/www/static;
37+
#}
3138
}
3239
}

0 commit comments

Comments
 (0)