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

Adding --wait to all cf run-task commands #4651

Merged
merged 2 commits into from
Jan 23, 2025
Merged

Adding --wait to all cf run-task commands #4651

merged 2 commits into from
Jan 23, 2025

Conversation

gsa-jrothacker
Copy link
Contributor

@gsa-jrothacker gsa-jrothacker commented Jan 22, 2025

Purpose

We recently found out that backup tasks were failing silently. Backup tasks are kicked off by github actions through a cloud foundry run-task command. By default this task is run asynchronously, and therefore the github action sees a success message when the task is started successfully. The purpose of this code change is ensure we can see the errors in the github workflow.

Issue

How

The cloud foundry run-task command accepts a --wait flag which will wait until the task is finished. If the task fails, the github workflow will fail.

Testing

I created a temporary script which always fails. (Since removed from the commit). I tested it using the deploy to preview workflow. You can see that here: https://github.com/GSA-TTS/FAC/actions/runs/12913210660/job/36010804577

Copy link
Contributor

github-actions bot commented Jan 22, 2025

Terraform plan for meta

No changes. Your infrastructure matches the configuration.
No changes. Your infrastructure matches the configuration.

Terraform has compared your real infrastructure against your configuration
and found no differences, so no changes are needed.

✅ Plan applied in Deploy to Development and Management Environment #925

Copy link
Contributor

github-actions bot commented Jan 22, 2025

Terraform plan for dev

Plan: 1 to add, 0 to change, 1 to destroy.
Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
-/+ destroy and then create replacement

Terraform will perform the following actions:

  # module.dev.module.cors.null_resource.cors_header must be replaced
-/+ resource "null_resource" "cors_header" {
!~      id       = "*******************" -> (known after apply)
!~      triggers = { # forces replacement
!~          "always_run" = "2025-01-23T18:22:03Z" -> (known after apply)
        }
    }

Plan: 1 to add, 0 to change, 1 to destroy.

✅ Plan applied in Deploy to Development and Management Environment #925

Copy link
Contributor

@asteel-gsa asteel-gsa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@asteel-gsa asteel-gsa added this pull request to the merge queue Jan 23, 2025
Merged via the queue into main with commit 719dff6 Jan 23, 2025
14 checks passed
@asteel-gsa asteel-gsa deleted the jr/backups branch January 23, 2025 19:53
Copy link
Contributor

Code Coverage

Package Line Rate Branch Rate Health
. 100% 100%
api 98% 90%
audit 97% 87%
audit.cross_validation 98% 88%
audit.fixtures 84% 50%
audit.intakelib 91% 81%
audit.intakelib.checks 92% 85%
audit.intakelib.common 98% 82%
audit.intakelib.transforms 100% 95%
audit.management.commands 78% 17%
audit.migrations 100% 100%
audit.models 94% 76%
audit.templatetags 100% 100%
audit.views 70% 53%
census_historical_migration 96% 65%
census_historical_migration.migrations 100% 100%
census_historical_migration.sac_general_lib 92% 84%
census_historical_migration.transforms 95% 90%
census_historical_migration.workbooklib 68% 69%
config 76% 31%
curation 100% 100%
curation.curationlib 93% 100%
curation.migrations 100% 100%
dissemination 91% 70%
dissemination.migrations 97% 25%
dissemination.searchlib 76% 66%
dissemination.templatetags 100% 100%
djangooidc 53% 38%
djangooidc.tests 100% 94%
report_submission 93% 88%
report_submission.migrations 100% 100%
report_submission.templatetags 74% 100%
support 91% 66%
support.migrations 100% 100%
support.models 96% 50%
tools 98% 50%
users 95% 92%
users.fixtures 100% 83%
users.management 100% 100%
users.management.commands 100% 100%
users.migrations 100% 100%
Summary 91% (18148 / 19934) 77% (2248 / 2934)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants