Last active
December 24, 2022 05:17
-
-
Save ans-4175/5ebfdce029f9ba5a4ed8f108df80378b to your computer and use it in GitHub Desktop.
Nginx Conf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
server_name www.sites.com; | |
# access_log /var/log/nginx/ops/access.log; | |
# error_log /var/log/nginx/ops/error.log; | |
location ~* ^/([^/]+) { | |
return 301 https://something.com?params=$1; | |
} | |
location /kontak { | |
if ($query_string ~ source=instagram) { | |
return 301 https://something.com/instagram?params=$1; | |
} | |
if ($query_string ~ source=tiktok) { | |
return 301 https://something.com/tiktok?params=$1; | |
} | |
return 301 https://something.com/default?params=$1; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment