Skip to content

Commit

Permalink
debug error
Browse files Browse the repository at this point in the history
  • Loading branch information
Jin-Sun-tts committed Jan 12, 2024
1 parent 3551779 commit f3b60a2
Show file tree
Hide file tree
Showing 2 changed files with 80 additions and 19 deletions.
75 changes: 61 additions & 14 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

jobs:
create-cloudgov-services-management-staging:
name:
name: create services (management-staging)
environment: management-staging
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -93,33 +93,66 @@ jobs:
sleep 150 # Logstash is very slow to start up
[ "401" = "$(curl -w '%{http_code}' --output /dev/null --silent https://logstash-stage-datagov.app.cloud.gov)" ]
drain-apps-in-management-staging:
name: drain everything in management-staging space
environment: management-staging
runs-on: ubuntu-latest
needs:
- deploy-management-staging
steps:
- name: checkout
uses: actions/checkout@v2
- name: drain-staging-space
uses: cloud-gov/cg-cli-tools@main
with:
command: |
./create-space-drain.sh management-staging
cf_org: gsa-datagov
cf_space: management-staging
cf_username: ${{secrets.CF_SERVICE_USER}}
cf_password: ${{secrets.CF_SERVICE_AUTH}}

drain-apps-in-staging:
name: drain everything in staging space
environment: management
environment: staging
runs-on: ubuntu-latest
needs:
- deploy-management
- deploy-management-staging
steps:
- name: checkout
uses: actions/checkout@v2
- name: drain-staging-space
uses: cloud-gov/cg-cli-tools@main
with:
command: |
apt install -y jq &&
curl -L -o drain-plugin https://github.com/cloudfoundry/cf-drain-cli/releases/download/v2.0.0/cf-drain-cli-linux &&
cf install-plugin -f -r drain-plugin &&
rm -f drain-plugin &&
mkdir -p /root/.cf/ && touch /root/.cf/config.json &&
./create-space-drain.sh management-staging
cf_org: gsa-datagov
cf_space: staging
cf_username: ${{secrets.CF_SERVICE_USER}}
cf_password: ${{secrets.CF_SERVICE_AUTH}}

drain-apps-in-management:
name: drain everything in management space
environment: management
runs-on: ubuntu-latest
needs:
- deploy-management
steps:
- name: checkout
uses: actions/checkout@v2
- name: drain-prod-space
uses: cloud-gov/cg-cli-tools@main
with:
command: |
./create-space-drain.sh management
cf_org: gsa-datagov
cf_space: management
cf_username: ${{secrets.CF_SERVICE_USER}}
cf_password: ${{secrets.CF_SERVICE_AUTH}}

drain-apps-in-prod:
name: drain everything in prod space
environment: management
environment: prod
runs-on: ubuntu-latest
needs:
- deploy-management
Expand All @@ -130,13 +163,27 @@ jobs:
uses: cloud-gov/cg-cli-tools@main
with:
command: |
apt install -y jq &&
curl -L -o drain-plugin https://github.com/cloudfoundry/cf-drain-cli/releases/download/v2.0.0/cf-drain-cli-linux &&
cf install-plugin -f -r drain-plugin &&
rm -f drain-plugin &&
mkdir -p /root/.cf/ && touch /root/.cf/config.json &&
./create-space-drain.sh management
cf_org: gsa-datagov
cf_space: prod
cf_username: ${{secrets.CF_SERVICE_USER}}
cf_password: ${{secrets.CF_SERVICE_AUTH}}

drain-apps-in-prod-egress:
name: drain everything in prod-egress space
environment: prod-egress
runs-on: ubuntu-latest
needs:
- deploy-management
steps:
- name: checkout
uses: actions/checkout@v2
- name: drain-prod-space
uses: cloud-gov/cg-cli-tools@main
with:
command: |
./create-space-drain.sh management
cf_org: gsa-datagov
cf_space: prod-egress
cf_username: ${{secrets.CF_SERVICE_USER}}
cf_password: ${{secrets.CF_SERVICE_AUTH}}
24 changes: 19 additions & 5 deletions .github/workflows/dev-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,25 @@ jobs:
sleep 150 # Logstash is very slow to start up
[ "401" = "$(curl -w '%{http_code}' --output /dev/null --silent https://logstash-development-datagov.app.cloud.gov)" ]
drain-apps-in-development-ssb:
name: drain everything in development-ssb space
environment: development-ssb
runs-on: ubuntu-latest
needs:
- deploy-development-ssb
steps:
- name: checkout
uses: actions/checkout@v2
- name: drain-development-space
uses: cloud-gov/cg-cli-tools@main
with:
command: |
./create-space-drain.sh development-ssb
cf_org: gsa-datagov
cf_space: development-ssb
cf_username: ${{secrets.CF_SERVICE_USER}}
cf_password: ${{secrets.CF_SERVICE_AUTH}}

drain-apps-in-development:
name: drain everything in development space
environment: development
Expand All @@ -63,11 +82,6 @@ jobs:
uses: cloud-gov/cg-cli-tools@main
with:
command: |
apt install -y jq &&
curl -L -o drain-plugin https://github.com/cloudfoundry/cf-drain-cli/releases/download/v2.0.0/cf-drain-cli-linux &&
cf install-plugin -f -r drain-plugin &&
rm -f drain-plugin &&
mkdir -p /root/.cf/ && touch /root/.cf/config.json &&
./create-space-drain.sh development-ssb
cf_org: gsa-datagov
cf_space: development
Expand Down

0 comments on commit f3b60a2

Please sign in to comment.