目标URL和发送域名填写COS的地址

#PROXY-START/

location ^~ /
{
    proxy_pass https://cvm-cos-1252138602.cos-website.ap-guangzhou.myqcloud.com;
    proxy_set_header Host cvm-cos-1252138602.cos-website.ap-guangzhou.myqcloud.com;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header REMOTE-HOST $remote_addr;
    
    add_header X-Cache $upstream_cache_status;
    
    #Set Nginx Cache
    
    
    set $static_fileQNkVRwYb 0;
    if ( $uri ~* "\.(gif|png|jpg|css|js|woff|woff2)$" )
    {
    	set $static_fileQNkVRwYb 1;
    	expires 12h;
        }
    if ( $static_fileQNkVRwYb = 0 )
    {
    add_header Cache-Control no-cache;
    }
}

#PROXY-END/