Jelajahi Sumber

[clsi] nginx: use a fixed project id for the content domain access check (#33291)

GitOrigin-RevId: 7801fa001e42b1b96d851f74efff396bc6471980
Jakob Ackermann 2 bulan lalu
induk
melakukan
666788be70
1 mengubah file dengan 2 tambahan dan 7 penghapusan
  1. 2 7
      services/clsi/nginx.conf

+ 2 - 7
services/clsi/nginx.conf

@@ -19,12 +19,7 @@ server {
   }
   }
 
 
   # user content domain access check
   # user content domain access check
-  # The project-id is zero prefixed. No actual user project uses these ids.
-  # mongo-id 000000000000000000000000 -> 1970-01-01T00:00:00.000Z
-  # mongo-id 000000010000000000000000 -> 1970-01-01T00:00:01.000Z
-  # mongo-id 100000000000000000000000 -> 1978-07-04T21:24:16.000Z
-  # This allows us to distinguish between check-traffic and regular output traffic.
-  location ~ ^/project/0([0-9a-f]+)/user/([0-9a-f]+)/build/([0-9a-f-]+)/output/output\.pdf$ {
+  location ~ ^/project/0cba050a0cec68384666fad1/user/([0-9a-f]+)/build/([0-9a-f-]+)/output/output\.pdf$ {
     if ($request_method = 'OPTIONS') {
     if ($request_method = 'OPTIONS') {
       # handle OPTIONS method for CORS requests
       # handle OPTIONS method for CORS requests
       add_header 'Allow' 'GET,HEAD';
       add_header 'Allow' 'GET,HEAD';
@@ -32,7 +27,7 @@ server {
     }
     }
     alias /var/clsi/tiny.pdf;
     alias /var/clsi/tiny.pdf;
   }
   }
-  location ~ ^/project/0([0-9a-f]+)/build/([0-9a-f-]+)/output/output\.pdf$ {
+  location ~ ^/project/0cba050a0cec68384666fad1/build/([0-9a-f-]+)/output/output\.pdf$ {
     if ($request_method = 'OPTIONS') {
     if ($request_method = 'OPTIONS') {
       # handle OPTIONS method for CORS requests
       # handle OPTIONS method for CORS requests
       add_header 'Allow' 'GET,HEAD';
       add_header 'Allow' 'GET,HEAD';