Nginx篇
ssl证书
分类
单域名证书
多域名证书
通用证书
网址
freessl
ohttps
ssh-keygen -R 114.132.70.81
www.lingyanspace.com_bundle.crt www.lingyanspace.com_bundle.pem www.lingyanspace.com.csr www.lingyanspace.com.key
/etc/nginx/www.lingyanspace.com_nginx
编译
yum install prel
yum install pcre cpre-devel
sudo yum install libxml2 libxml2-devel libxslt libxslt-devel
sudo yum install gd gd-devel
load_module /usr/lib64/nginx/modules/ngx_http_image_filter_module.so
load_module /usr/lib64/nginx/modules/ngx_http_perl_module.so
load_module /usr/lib64/nginx/modules/ngx_http_xslt_filter_module.so
load_module /usr/lib64/nginx/modules/ngx_mail_module.so
load_module /usr/lib64/nginx/modules/ngx_stream_module.so
#vod caches
vod_metadata_cache metadata_cache 256m;
vod_response_cache response_cache 128m;
# vod settings
vod_mode local;
vod_segment_duration 2000; # 2s
vod_align_segments_to_key_frames on;
#file handle caching / aio
open_file_cache max=1000 inactive=5m;
open_file_cache_valid 2m;
open_file_cache_min_uses 1;
open_file_cache_errors on;
aio on;
#课程权限文件夹
location /LimitVideo/ {
auth_request /test_auth;
alias /home/lingyanspace/LimitVideo/;
vod hls;
add_header Access-Control-Allow-Headers '*';
add_header Access-Control-Expose-Headers 'Server,range,Content-Length,Content-Range';
add_header Access-Control-Allow-Methods 'GET, HEAD, OPTIONS';
add_header Access-Control-Allow-Origin '*';
expires 100d;
}
location =/test_auth {
proxy_pass http://127.0.0.1:7777/LimitVideo;
proxy_pass_request_body off;
proxy_set_header X-Original-URI $request_uri;
proxy_set_header X-Original-Method $request_method;
proxy_set_header X-Forwarded-Proto $scheme;
}
//路径标识
public string LimitVideo = "LimitVideo";
public string LimitFile = "LimitFile";
public string OpenFile = "OpenFile";