From 47ed207a323edb29d233421ac776344e6a01eb85 Mon Sep 17 00:00:00 2001 From: Elliot Voris Date: Mon, 1 Jul 2024 12:59:15 -0500 Subject: [PATCH 1/4] remove unnecessary slash from a horizon redirect --- nginx/includes/redirects.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nginx/includes/redirects.conf b/nginx/includes/redirects.conf index b3c87be96..f6101130a 100644 --- a/nginx/includes/redirects.conf +++ b/nginx/includes/redirects.conf @@ -36,7 +36,7 @@ rewrite ^/docs/fundamentals-and-concepts/testnet-and-pubnet$ "/docs/learn/fundam rewrite ^/api$ "/docs/data/horizon" permanent; # moving /api/* locations to /api/horizon (leaving /api intact for the "overview page") rewrite ^/api(/(?!horizon|(anchor|stellar-disbursement)-platform).*)$ "/docs/data/horizon$1" permanent; -rewrite ^/(network|api)/horizon(.*)$ "/docs/data/horizon/$2" permanent; +rewrite ^/(network|api)/horizon(.*)$ "/docs/data/horizon$2" permanent; rewrite ^/(network|api)/((anchor|stellar-disbursement)-platform)(.*)$ "/platforms/$2$4" permanent; rewrite ^/network/horizon/(resources|structure|aggregations|errors)(.*)$ "/docs/data/horizon/api-reference/$1$2" permanent; rewrite ^/network/soroban-rpc/(methods|json-rpc|pagination)(.*)$ "/docs/data/rpc/api-reference/$1$2" permanent; From 7f83b88298538936e034f637406cb1ace098a3b6 Mon Sep 17 00:00:00 2001 From: Elliot Voris Date: Mon, 1 Jul 2024 13:46:59 -0500 Subject: [PATCH 2/4] reorder redirects for api references --- nginx/includes/redirects.conf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nginx/includes/redirects.conf b/nginx/includes/redirects.conf index f6101130a..412517a42 100644 --- a/nginx/includes/redirects.conf +++ b/nginx/includes/redirects.conf @@ -36,12 +36,12 @@ rewrite ^/docs/fundamentals-and-concepts/testnet-and-pubnet$ "/docs/learn/fundam rewrite ^/api$ "/docs/data/horizon" permanent; # moving /api/* locations to /api/horizon (leaving /api intact for the "overview page") rewrite ^/api(/(?!horizon|(anchor|stellar-disbursement)-platform).*)$ "/docs/data/horizon$1" permanent; -rewrite ^/(network|api)/horizon(.*)$ "/docs/data/horizon$2" permanent; -rewrite ^/(network|api)/((anchor|stellar-disbursement)-platform)(.*)$ "/platforms/$2$4" permanent; rewrite ^/network/horizon/(resources|structure|aggregations|errors)(.*)$ "/docs/data/horizon/api-reference/$1$2" permanent; -rewrite ^/network/soroban-rpc/(methods|json-rpc|pagination)(.*)$ "/docs/data/rpc/api-reference/$1$2" permanent; +rewrite ^/(network|api)/horizon(.*)$ "/docs/data/horizon$2" permanent; rewrite ^/network/anchor-platform/(resources|callbacks|custody-server|rpc)(.*)$ "/platforms/anchor-platform/api-reference/$1$2" permanent; rewrite ^/network/stellar-disbursement-platform/resources(.*)$ "/platforms/stellar-disbursement-platform/api-reference$1" permanent; +rewrite ^/(network|api)/((anchor|stellar-disbursement)-platform)(.*)$ "/platforms/$2$4" permanent; +rewrite ^/network/soroban-rpc/(methods|json-rpc|pagination)(.*)$ "/docs/data/rpc/api-reference/$1$2" permanent; # moving /ap_api locations to /api/anchor-platform rewrite ^/ap_api(.*)?$ "/platforms/anchor-platform$1" permanent; rewrite ^/docs/category/anchor-platform$ "/platforms/anchor-platform/admin-guide" permanent; From 44f71d935aaf06b2ca448f79394aad0d4b85d934 Mon Sep 17 00:00:00 2001 From: Elliot Voris Date: Mon, 1 Jul 2024 13:54:47 -0500 Subject: [PATCH 3/4] fix redirects for hubble --- nginx/includes/redirects.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/nginx/includes/redirects.conf b/nginx/includes/redirects.conf index 412517a42..25a3d4864 100644 --- a/nginx/includes/redirects.conf +++ b/nginx/includes/redirects.conf @@ -125,6 +125,7 @@ rewrite ^/docs/learn/encyclopedia/signatures-multisig$ "/docs/learn/encyclopedia rewrite ^/docs/learn/encyclopedia/sponsored-reserves$ "/docs/learn/encyclopedia/transactions-specialized/sponsored-reserves" permanent; rewrite ^/docs/learn/encyclopedia/xdr$ "/docs/learn/encyclopedia/data-format/xdr" permanent; rewrite ^/network/core-node(.*)$ "/docs/validators$1" permanent; +rewrite ^/network/hubble/(connecting|optimizing-queries|viewing-metadata)(.*)$ "/docs/data/hubble/analyst-guide/$1$2" permanent; rewrite ^/network/hubble(.*) "/docs/data/hubble$1" permanent; rewrite ^/network/soroban-rpc(.*) "/docs/data/rpc$1" permanent; rewrite ^/network/horizon(.*) "/docs/data/horizon$1" permanent; From f8100f69155385d661f53afb389c649d33e91907 Mon Sep 17 00:00:00 2001 From: Elliot Voris Date: Mon, 1 Jul 2024 14:02:22 -0500 Subject: [PATCH 4/4] fix some redirects for RPC --- nginx/includes/redirects.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nginx/includes/redirects.conf b/nginx/includes/redirects.conf index 25a3d4864..7af987698 100644 --- a/nginx/includes/redirects.conf +++ b/nginx/includes/redirects.conf @@ -69,8 +69,8 @@ rewrite ^/docs/learn$ "/docs/learn/fundamentals" permanent; rewrite ^/docs/learn/smart-contract-internals/fees-and-metering$ "/docs/learn/fundamentals/fees-resource-limits-metering" permanent; rewrite ^/docs/learn/migrate/introduction-to-solidity-and-rust$ "/docs/learn/migrate/evm/introduction-to-solidity-and-rust" permanent; rewrite ^/docs/learn/smart-contract-internals/state-expiration$ "/docs/learn/smart-contract-internals/state-archival" permanent; -rewrite ^/platforms/soroban-rpc/methods(.*)$ "/docs/data/rpc/methods$1" permanent; -rewrite ^/network/soroban-rpc/getEvents$ "/docs/data/rpc/methods/getEvents" permanent; +rewrite ^/platforms/soroban-rpc/methods(.*)$ "/docs/data/rpc/api-reference/methods$1" permanent; +rewrite ^/network/soroban-rpc/getEvents$ "/docs/data/rpc/api-reference/methods/getEvents" permanent; rewrite ^/docs/smart-contracts/example-contracts/stellar-asset-contract$ "/docs/smart-contracts/tokens/stellar-asset-contract" permanent; rewrite ^/docs/smart-contracts/faq "/docs/smart-contracts#soroban-faqs" permanent; rewrite ^/docs/learn/smart-contract-internals/faq "/docs/smart-contracts#soroban-faqs" permanent;