mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-08-11 20:19:38 +02:00
Update clone-staging.yaml
This commit is contained in:
parent
820d22f90d
commit
48eb586b92
1 changed files with 7 additions and 7 deletions
14
.github/workflows/clone-staging.yaml
vendored
14
.github/workflows/clone-staging.yaml
vendored
|
@ -18,8 +18,8 @@ jobs:
|
||||||
clone-database:
|
clone-database:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
CF_USERNAME: CF_MS_USERNAME
|
CF_USERNAME: ${{ secrets[env.CF_USERNAME] }}
|
||||||
CF_PASSWORD: CF_MS_PASSWORD
|
CF_PASSWORD: ${{ secrets[env.CF_PASSWORD] }}
|
||||||
steps:
|
steps:
|
||||||
- name: Clone Database
|
- name: Clone Database
|
||||||
run: |
|
run: |
|
||||||
|
@ -34,14 +34,14 @@ jobs:
|
||||||
|
|
||||||
# Authenticate and target CF org and space.
|
# Authenticate and target CF org and space.
|
||||||
cf api api.fr.cloud.gov
|
cf api api.fr.cloud.gov
|
||||||
cf auth ${{ secrets[env.CF_USERNAME] }} ${{ secrets[env.CF_PASSWORD] }}
|
cf auth $CF_USERNAME $CF_PASSWORD
|
||||||
cf target -o cisa-dotgov -s ${{ env.DESTINATION_ENVIRONMENT }}
|
cf target -o cisa-dotgov -s $DESTINATION_ENVIRONMENT
|
||||||
|
|
||||||
# share the target db with the source space
|
# share the target db with the source space
|
||||||
cf share-service getgov-${{ env.DESTINATION_ENVIRONMENT }}-database -s ${{ env.SOURCE_ENVIRONMENT }}
|
cf share-service getgov-$DESTINATION_ENVIRONMENT-database -s $SOURCE_ENVIRONMENT
|
||||||
|
|
||||||
# clone from source to destination
|
# clone from source to destination
|
||||||
cg-manage-rds clone getgov-${{ env.DESTINATION_ENVIRONMENT }}-database getgov-${{ env.SOURCE_ENVIRONMENT }}-database
|
cg-manage-rds clone getgov-$DESTINATION_ENVIRONMENT-database getgov-$SOURCE_ENVIRONMENT-database
|
||||||
|
|
||||||
# unshare the service
|
# unshare the service
|
||||||
cf unshare-service getgov-${{ env.DESTINATION_ENVIRONMENT }}-database -s ${{ env.SOURCE_ENVIRONMENT }}
|
cf unshare-service getgov-$DESTINATION_ENVIRONMENT-database -s $SOURCE_ENVIRONMENT
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue