Update nginx to 1.7.5 and always send CORS header
*add_header [...] always* requires >= 1.7.5 as per https://nginx.org/en/docs/http/ngx_http_headers_module.html
This commit is contained in:
parent
1886f11f9b
commit
68d22195f3
@ -26,16 +26,16 @@ RUN apt-get update && \
|
|||||||
|
|
||||||
# get nginx source
|
# get nginx source
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
RUN wget http://nginx.org/download/nginx-1.6.2.tar.gz && \
|
RUN wget http://nginx.org/download/nginx-1.7.5tar.gz && \
|
||||||
tar zxf nginx-1.6.2.tar.gz && \
|
tar zxf nginx-1.7.5.tar.gz && \
|
||||||
rm nginx-1.6.2.tar.gz && \
|
rm nginx-1.7.5.tar.gz && \
|
||||||
# get nginx-rtmp module
|
# get nginx-rtmp module
|
||||||
wget https://github.com/arut/nginx-rtmp-module/archive/v1.1.6.tar.gz && \
|
wget https://github.com/arut/nginx-rtmp-module/archive/v1.1.6.tar.gz && \
|
||||||
tar zxf v1.1.6.tar.gz && \
|
tar zxf v1.1.6.tar.gz && \
|
||||||
rm v1.1.6.tar.gz
|
rm v1.1.6.tar.gz
|
||||||
|
|
||||||
# compile nginx
|
# compile nginx
|
||||||
WORKDIR /src/nginx-1.6.2
|
WORKDIR /src/nginx-1.7.5
|
||||||
RUN ./configure --add-module=/src/nginx-rtmp-module-1.1.6 \
|
RUN ./configure --add-module=/src/nginx-rtmp-module-1.1.6 \
|
||||||
--conf-path=/config/nginx.conf \
|
--conf-path=/config/nginx.conf \
|
||||||
--error-log-path=/logs/error.log \
|
--error-log-path=/logs/error.log \
|
||||||
|
@ -48,7 +48,7 @@ http {
|
|||||||
}
|
}
|
||||||
root /data;
|
root /data;
|
||||||
add_header Cache-Control no-cache;
|
add_header Cache-Control no-cache;
|
||||||
add_header Access-Control-Allow-Origin *;
|
add_header Access-Control-Allow-Origin * always;
|
||||||
}
|
}
|
||||||
|
|
||||||
location /stat {
|
location /stat {
|
||||||
|
Loading…
Reference in New Issue
Block a user