Skip to content

Commit

Permalink
Added bundle_and_release.yml to push redirect
Browse files Browse the repository at this point in the history
removed raat-redirect

added raat-redirect
  • Loading branch information
HauwaHakimi committed Feb 23, 2024
1 parent 3af6143 commit 8889d6a
Show file tree
Hide file tree
Showing 5 changed files with 72 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/bundle_and_release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: release-re-request-an-aws-account

on:
push:
branches: [ main ]

workflow_dispatch:
jobs:
build-release:
runs-on: ubuntu-latest
environment: production
steps:
- uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579
- name: add-cloudfoundry-repository
run: |
wget -q -O - https://packages.cloudfoundry.org/debian/cli.cloudfoundry.org.key | sudo apt-key add -
echo "deb https://packages.cloudfoundry.org/debian stable main" | sudo tee /etc/apt/sources.list.d/cloudfoundry-cli.list
- name: deploy-redirect
env:
CF_USERNAME: ${{ secrets.CF_EMAIL }}
CF_PASSWORD: ${{ secrets.CF_PASSWORD }}
run: |
cf api https://api.cloud.service.gov.uk
cf auth
cf target -o gds-tech-ops -s re-aws-account-management
cf push -f ./raat-redirect/manifest.yml --strategy rolling
3 changes: 3 additions & 0 deletions raat-redirect/buildpack.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
nginx:
version: mainline
15 changes: 15 additions & 0 deletions raat-redirect/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=request-an-aws-account.gds-reliability.engineering">
<meta charset="UTF-8">
<title>This site has moved</title>
<meta name="description" content="Request an aws account tool has moved to a new address. Please note the change of address." >
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<section>
<h2>This site has moved to <a href="https://request-an-aws-account.gds-reliability.engineering">https://request-an-aws-account.gds-reliability.engineering</a></h2>
</section>
</body>
</html>
8 changes: 8 additions & 0 deletions raat-redirect/manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
applications:
- name: gds-request-an-aws-account-redirect
memory: 128M
instances: 1
path: .


18 changes: 18 additions & 0 deletions raat-redirect/nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
worker_processes 1;
daemon off;

error_log stderr;

events {
worker_connections 1024;
}

http {
server {
listen {{port}};
server_name localhost;

# Redirect all traffic to the new URL
return 301 https://request-an-aws-account.gds-reliability.engineering$request_uri;
}
}

0 comments on commit 8889d6a

Please sign in to comment.