Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DOP-4589: Create bucket-level redirects for several versions #1046

Merged
merged 2 commits into from
May 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 63 additions & 7 deletions infrastructure/ecs-main/buckets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,24 @@ Resources:
IndexDocument: index.html
ErrorDocument: ${self:custom.site.errorDoc.${self:provider.stage}, null}
RoutingRules:
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/stable
RedirectRule:
Protocol: "https"
HostName: ${self:custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/manual
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/master
RedirectRule:
Protocol: "https"
HostName: ${self:custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/upcoming
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/manual
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/current
RedirectRule:
Protocol: "https"
HostName: ${self:custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/manual
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/atlas/cli/v1.3.0
RedirectRule:
Expand Down Expand Up @@ -131,25 +143,31 @@ Resources:
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/stable
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/v1.0
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/v1
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/stable
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/v1
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/stable
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/stable
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/kubernetes-operator/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/mongocli/v0.
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/mongocli/stable
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/mongocli/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/mongocli/stable
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/mongocli/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/spark-connector/v1.1
RedirectRule:
Expand All @@ -168,6 +186,24 @@ Resources:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/spark-connector/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/ruby-driver/master
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/ruby-driver/upcoming
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/compass/beta
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/compass/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/compass/upcoming
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/compass/current
DocAtlasBucket:
Type: "AWS::S3::Bucket"
Properties:
Expand All @@ -180,6 +216,18 @@ Resources:
WebsiteConfiguration:
IndexDocument: index.html
ErrorDocument: ${self:custom.site.errorDoc.${self:provider.stage}, null}
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/atlas/cli/stable
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/atlas/cli/current
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/atlas/atlas-operator/stable
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/atlas/atlas-operator/current
CloudManagerBucket:
Type: "AWS::S3::Bucket"
Properties:
Expand Down Expand Up @@ -270,6 +318,14 @@ Resources:
WebsiteConfiguration:
IndexDocument: index.html
ErrorDocument: ${self:custom.site.errorDoc.${self:provider.stage}, null}
RoutingRules:
- RoutingRuleCondition:
KeyPrefixEquals: ${self:custom.site.prefix.${self:provider.stage}}/languages/scala/driver/master
RedirectRule:
Protocol: "https"
HostName: ${self.custom.site.host.${self:provider.stage}}
ReplaceKeyPrefixWith: ${self:custom.site.prefix.${self:provider.stage}}/languages/scala/driver/upcoming


DocsBucketPolicy:
Type: AWS::S3::BucketPolicy
Expand Down
Loading