Merge branch 'master' of github.com:IoTcat/ushio-etc

master
usa.yimian.xyz 4 years ago
commit 50521173fb
  1. 40
      cn.yimian.xyz/nginx/conf.d/cp-acc.yimian.xyz.conf
  2. 34
      cn.yimian.xyz/nginx/conf.d/guide.yimian.xyz.conf
  3. 17
      cn.yimian.xyz/nginx/conf.d/img.yimian.xyz.conf
  4. 11
      common/frp/frpc.ini.home
  5. 30
      home.yimian.xyz/nginx/conf.d/git.yimian.xyz.conf

@ -0,0 +1,40 @@
server {
listen 80;
#listen [::]:80;
server_name cp-acc.yimian.xyz;
rewrite ^(.*)$ https://$host$1 permanent;
}
server {
# listen 80;
# listen [::]:80;
listen 443 ssl;
server_name cp-acc.yimian.xyz;
root /home/www/cp-acc;
index index.php index.html;
ssl_certificate /mnt/config/ssl/yimian.xyz/yimian.xyz.crt; #2
ssl_certificate_key /mnt/config/ssl/yimian.xyz/yimian.xyz.key; #3
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
# error_page 404 = /404.php;
# Load configuration files for the default server block.
include /mnt/etc/common/nginx/default.d/*.conf;
error_page 404 /404.html;
location = /40x.html {
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
}
}

@ -0,0 +1,34 @@
server {
listen 80;
#listen [::]:80;
server_name guide.yimian.xyz;
rewrite ^(.*)$ https://$host$1 permanent;
}
server {
# listen 80;
# listen [::]:80;
listen 443 ssl;
server_name guide.yimian.xyz;
root /home/www/guide;
index index.php index.html;
client_max_body_size 50m;
ssl_certificate /mnt/config/ssl/yimian.xyz/yimian.xyz.crt; #2
ssl_certificate_key /mnt/config/ssl/yimian.xyz/yimian.xyz.key; #3
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
# error_page 404 = /404.php;
# Load configuration files for the default server block.
include /mnt/etc/common/nginx/default.d/*.conf;
location / {
}
}

@ -12,7 +12,7 @@ server {
listen 443 ssl;
server_name img.yimian.xyz;
root /home/www/img;
root /home/www/img/;
index index.php index.html;
ssl_certificate /mnt/config/ssl/yimian.xyz/yimian.xyz.crt; #2
@ -25,17 +25,10 @@ server {
ssl_prefer_server_ciphers on;
# error_page 404 = /404.php;
location / {
if (-f $request_filename/index.html){
rewrite (.*) $1/index.html break;
}
if (-f $request_filename/index.php){
rewrite (.*) $1/index.php;
}
if (!-f $request_filename){
rewrite (.*) /index.php;
}
}
if (-f $request_filename/index.html){ rewrite (.*) $1/index.html break; }
if (-f $request_filename/index.php){ rewrite (.*) $1/index.php; }
if (!-f $request_filename){ rewrite (.*) /index.php; }
if (!-e $request_filename) { rewrite ^(.*)$ /index.php$1 last; }
# Load configuration files for the default server block.
include /mnt/etc/common/nginx/default.d/*.conf;

@ -22,3 +22,14 @@ custom_domains = docker.yimian.xyz
type = https
local_port = 443
custom_domains = v-china.yimian.xyz
[ushio_git]
type = https
local_port = 443
custom_domains = git.yimian.xyz
[ushio_git_ssh]
type = tcp
local_port = 222
local_ip = 127.0.0.1
remote_port = 4422

@ -0,0 +1,30 @@
server {
listen 80;
#listen [::]:80;
server_name git.yimian.xyz;
rewrite ^(.*)$ https://$host$1 permanent;
}
server {
#listen 80;
listen 443 ssl;
server_name git.yimian.xyz;
ssl_certificate /mnt/config/ssl/yimian.xyz/yimian.xyz.crt;
ssl_certificate_key /mnt/config/ssl/yimian.xyz/yimian.xyz.key;
location / {
proxy_pass http://gitea:3000/;
proxy_read_timeout 300s;
proxy_send_timeout 300s;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
}
}
Loading…
Cancel
Save