-
Notifications
You must be signed in to change notification settings - Fork 16
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
CAPT-1702 Migrate test environment to AKS #2815
Merged
AbigailMcP
merged 14 commits into
master
from
CAPT-1702-migrate-test-environment-to-aks
Jun 21, 2024
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
715603d
Add test env variables
AbigailMcP 1269193
Add startup commands and test_app_env.yml
AbigailMcP 9f2bdd6
Add test deploy to workflow
AbigailMcP 52c7332
Update canonical_hostname and add postgres extensions
AbigailMcP 4d98c02
Update build_and_deploy workflow to run on push to master, not main
AbigailMcP 09dbda2
Run DB migrations when deploying the test environment
vacabor 1aa731a
Add 2 app replicas
AbigailMcP 6db8713
Configure SemanticLogger per tech guidance
vacabor b5bfd33
Revert "Configure SemanticLogger per tech guidance"
vacabor c5d2de5
Use app_replicas variable in web_application module
AbigailMcP 66fbeef
CAPT-1702 Add slack notification on failure (#2864)
184e80d
Rename app_replicas => web_replicas
AbigailMcP c8f9f3e
Update worker command
AbigailMcP d3cd5c4
CAPT-1702 Add smoke test (#2875)
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
require "rails_helper" | ||
|
||
RSpec.describe "Start a claim", :smoke, type: :feature do | ||
# To test this locally you will need to add to your .env file: | ||
# | ||
# SMOKE_TEST_APP_HOST | ||
# BASIC_AUTH_USERNAME | ||
# BASIC_AUTH_PASSWORD | ||
|
||
scenario "User starts a claim" do | ||
visit url_with_basic_auth | ||
expect(page).to have_text("Teachers: claim back your student loan repayments") | ||
end | ||
|
||
def url_with_basic_auth | ||
host = ENV.fetch("SMOKE_TEST_APP_HOST") | ||
path = new_claim_path(Journeys::TeacherStudentLoanReimbursement::ROUTING_NAME) | ||
uri = URI.join(host, path) | ||
|
||
uri.user = ENV.fetch("BASIC_AUTH_USERNAME", nil) | ||
uri.password = ENV.fetch("BASIC_AUTH_PASSWORD", nil) | ||
uri.to_s | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"cluster": "test", | ||
"namespace": "srtl-test", | ||
"config": "test", | ||
"environment": "test", | ||
"canonical_hostname": "claim-additional-payments-for-teaching-test-web.test.teacherservices.cloud", | ||
"web_replicas": 2, | ||
"startup_command": ["/bin/sh", "-c", "bin/rails server -b 0.0.0.0"], | ||
"worker_command": ["/bin/sh", "-c", "bin/bundle exec bin/delayed_job run -n 1"] | ||
} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. the claim-additional-payments-for-teaching-test-web deployment should have 2 replicas |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
aks: | ||
source: "https://github.com/DFE-Digital/terraform-modules" | ||
version: "testing" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--- | ||
SUPPRESS_DFE_ANALYTICS_INIT: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We normally have a smoke test post deployment for permanent env deployments (i.e. test/prod), and also look to have a slack msg generated on workflow failure (of perm env deploy/smoke test failure)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
smoke test PR: #2875
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
slack message PR: #2864