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

MAIN B-22272 #14676

Closed
wants to merge 19 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
81f7b95
initial commit, using existing work from 21940 but will change this t…
danieljordan-caci Dec 10, 2024
263e5f6
most of it is working, just need to get clarification on move_to_gblo…
danieljordan-caci Jan 24, 2025
74b5d09
refactoring using USING, need to add USMC logic and refine
danieljordan-caci Jan 27, 2025
5fb02b3
added move to dest gbloc view
danieljordan-caci Jan 28, 2025
4a2ab0d
updating move_to_gbloc to move_to_dest_gbloc
danieljordan-caci Jan 29, 2025
c997ab5
adding things, awaiting db funcs from beth for USMC logic
danieljordan-caci Jan 31, 2025
f909614
Merge remote-tracking branch 'origin/main' into MAIN-B-22272
danieljordan-caci Feb 4, 2025
3017925
Merge remote-tracking branch 'origin/B-21583-gbloc-AK-moves' into MAI…
danieljordan-caci Feb 4, 2025
7112520
dear gawd I think I have it working - need tests
danieljordan-caci Feb 4, 2025
00d115c
Merge branch 'main' into MAIN-B-22272
danieljordan-caci Feb 4, 2025
df78bf3
cleanup before adding tests
danieljordan-caci Feb 4, 2025
0aa8ab6
are you mocking me?
danieljordan-caci Feb 4, 2025
afc09c9
Merge remote-tracking branch 'refs/remotes/origin/MAIN-B-22272' into …
danieljordan-caci Feb 4, 2025
6e0a061
added order_fetcher tests
danieljordan-caci Feb 5, 2025
f680a0b
added test for handler
danieljordan-caci Feb 5, 2025
ce1423e
added address update to test
danieljordan-caci Feb 6, 2025
4fedc40
query improvements, updating csv file name prefix
danieljordan-caci Feb 7, 2025
f4ce771
test adjustments
danieljordan-caci Feb 7, 2025
e38c863
updating to include moves.show in return
danieljordan-caci Feb 7, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 22 additions & 22 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1249,7 +1249,7 @@ push_otel_collector_image_dp3:

deploy_migrations_dp3:
stage: deploy
resource_group: $DP3_ENV
resource_group: $DP3_ENV_migration
tags:
- $RUNNER_TAG
environment: $DP3_ENV
Expand Down Expand Up @@ -1281,7 +1281,7 @@ deploy_migrations_dp3:

deploy_tasks_dp3:
stage: deploy
resource_group: $DP3_ENV
resource_group: $DP3_ENV_task
tags:
- $RUNNER_TAG
environment: $DP3_ENV
Expand Down Expand Up @@ -1310,7 +1310,7 @@ deploy_tasks_dp3:

deploy_app_client_tls_dp3:
stage: deploy
resource_group: $DP3_ENV
resource_group: $DP3_ENV_client
tags:
- $RUNNER_TAG
environment: $DP3_ENV
Expand Down Expand Up @@ -1352,7 +1352,7 @@ deploy_app_client_tls_dp3:

deploy_app_dp3:
stage: deploy
resource_group: $DP3_ENV
resource_group: $DP3_ENV_app
tags:
- $RUNNER_TAG
environment: $DP3_ENV
Expand Down Expand Up @@ -1515,7 +1515,7 @@ push_otel_collector_image_stg:

deploy_migrations_stg:
stage: deploy
resource_group: staging
resource_group: staging_migration
tags:
- $RUNNER_TAG
environment: stg
Expand Down Expand Up @@ -1547,7 +1547,7 @@ deploy_migrations_stg:

deploy_tasks_stg:
stage: deploy
resource_group: staging
resource_group: staging_task
tags:
- $RUNNER_TAG
environment: stg
Expand Down Expand Up @@ -1576,7 +1576,7 @@ deploy_tasks_stg:

deploy_app_client_tls_stg:
stage: deploy
resource_group: staging
resource_group: staging_client
environment: stg
image:
name: $DOCKER_APP_IMAGE
Expand Down Expand Up @@ -1617,7 +1617,7 @@ deploy_app_client_tls_stg:

deploy_app_stg:
stage: deploy
resource_group: staging
resource_group: staging_app
tags:
- $RUNNER_TAG
environment: stg
Expand Down Expand Up @@ -1690,7 +1690,7 @@ prod_approval:

build_push_app_prd:
stage: push_prd
resource_group: production
resource_group: production_app
environment: prd
image:
name: gcr.io/kaniko-project/executor:v1.14.0-debug
Expand All @@ -1713,7 +1713,7 @@ build_push_app_prd:

build_push_migrations_prd:
stage: push_prd
resource_group: production
resource_group: production_migration
tags:
- $RUNNER_TAG
environment: prd
Expand All @@ -1738,7 +1738,7 @@ build_push_migrations_prd:

build_push_tasks_prd:
stage: push_prd
resource_group: production
resource_group: production_task
environment: prd
tags:
- $RUNNER_TAG
Expand All @@ -1763,7 +1763,7 @@ build_push_tasks_prd:

push_otel_collector_image_prd:
stage: push_prd
resource_group: production
resource_group: production_otel
tags:
- $RUNNER_TAG
environment: prd
Expand Down Expand Up @@ -1800,7 +1800,7 @@ push_otel_collector_image_prd:

deploy_migrations_prd:
stage: deploy_prd
resource_group: production
resource_group: production_migration
environment: prd
tags:
- $RUNNER_TAG
Expand Down Expand Up @@ -1832,7 +1832,7 @@ deploy_migrations_prd:

deploy_tasks_prd:
stage: deploy_prd
resource_group: production
resource_group: production_task
environment: prd
tags:
- $RUNNER_TAG
Expand Down Expand Up @@ -1861,7 +1861,7 @@ deploy_tasks_prd:

deploy_app_client_tls_prd:
stage: deploy_prd
resource_group: production
resource_group: production_client
environment: prd
tags:
- $RUNNER_TAG
Expand Down Expand Up @@ -1892,19 +1892,19 @@ deploy_app_client_tls_prd:
- ./scripts/ecs-deploy-service-container app-client-tls "${ECR_REPOSITORY_URI}/app@${ECR_DIGEST}" "${APP_ENVIRONMENT}" "/bin/milmove serve"
#TODO: fix domain make dynamic and pass in preferred
- echo "Running Health Check"
- bin/health-checker --schemes https --hosts api.$APP_ENVIRONMENT.move.mil --key ${TLS_KEY} --cert ${TLS_CERT} --ca ${TLS_CA} --tries 10 --backoff 3 --log-level info --timeout 5m
- bin/health-checker --schemes https --hosts api.move.mil --key ${TLS_KEY} --cert ${TLS_CERT} --ca ${TLS_CA} --tries 10 --backoff 3 --log-level info --timeout 5m
- echo "Running TLS Check"
- bin/tls-checker --schemes https --hosts api.$APP_ENVIRONMENT.move.mil --key ${TLS_KEY} --cert ${TLS_CERT} --ca ${TLS_CA} --log-level info --timeout 15m
- bin/tls-checker --schemes https --hosts api.move.mil --key ${TLS_KEY} --cert ${TLS_CERT} --ca ${TLS_CA} --log-level info --timeout 15m
- echo "Checking deployed commits"
- ./scripts/check-deployed-commit "api.$APP_ENVIRONMENT.move.mil" "$CI_COMMIT_SHA" ${TLS_KEY} ${TLS_CERT} ${TLS_CA}
- ./scripts/check-deployed-commit "api.move.mil" "$CI_COMMIT_SHA" ${TLS_KEY} ${TLS_CERT} ${TLS_CA}
after_script:
- *announce_failure
rules:
- *check_main

deploy_app_prd:
stage: deploy_prd
resource_group: production
resource_group: production_app
tags:
- $RUNNER_TAG
environment: prd
Expand Down Expand Up @@ -1944,11 +1944,11 @@ deploy_app_prd:
- ./scripts/ecs-deploy-service-container app "${ECR_REPOSITORY_URI}/app@${ECR_DIGEST}" "${APP_ENVIRONMENT}" "/bin/milmove serve"
#TODO: fix domain make dynamic and pass in preferred
- echo "Running Health Check"
- bin/health-checker --schemes https --hosts my.$APP_ENVIRONMENT.move.mil,office.$APP_ENVIRONMENT.move.mil,admin.$APP_ENVIRONMENT.move.mil --tries 10 --backoff 3 --log-level info --timeout 5m
- bin/health-checker --schemes https --hosts my.move.mil,office.move.mil,admin.move.mil --tries 10 --backoff 3 --log-level info --timeout 5m
- echo "Running TLS Check"
- bin/tls-checker --schemes https --hosts my.$APP_ENVIRONMENT.move.mil,office.$APP_ENVIRONMENT.move.mil,admin.$APP_ENVIRONMENT.move.mil --log-level info --timeout 15m
- bin/tls-checker --schemes https --hosts my.move.mil,office.move.mil,admin.move.mil --log-level info --timeout 15m
- echo "Checking deployed commits"
- ./scripts/check-deployed-commit "my.$APP_ENVIRONMENT.move.mil,office.$APP_ENVIRONMENT.move.mil,admin.$APP_ENVIRONMENT.move.mil" "$CI_COMMIT_SHA"
- ./scripts/check-deployed-commit "my.move.mil,office.move.mil,admin.move.mil" "$CI_COMMIT_SHA"
after_script:
- *announce_failure
rules:
Expand Down
44 changes: 3 additions & 41 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -1209,44 +1209,6 @@ anti_virus: ## Scan repo with anti-virus service

.PHONY: nonato_deploy_prepare
nonato_deploy_prepare: ## Replace placeholders in config to deploy to a non-ATO env. Requires DEPLOY_ENV to be set to exp, loadtest, or demo.
ifeq ($(DEPLOY_ENV), exp)
@echo "Preparing for deploy to experimental"
else ifeq ($(DEPLOY_ENV), loadtest)
@echo "Preparing for deploy to loadtest"
else ifeq ($(DEPLOY_ENV), demo)
@echo "Preparing for deploy to demo"
else
$(error DEPLOY_ENV must be exp, loadtest, or demo)
endif
sed -E -i '' "s#(&dp3-branch) placeholder_branch_name#\1 $(GIT_BRANCH)#" .circleci/config.yml
sed -E -i '' "s#(&integration-ignore-branch) placeholder_branch_name#\1 $(GIT_BRANCH)#" .circleci/config.yml
sed -E -i '' "s#(&integration-mtls-ignore-branch) placeholder_branch_name#\1 $(GIT_BRANCH)#" .circleci/config.yml
sed -E -i '' "s#(&client-ignore-branch) placeholder_branch_name#\1 $(GIT_BRANCH)#" .circleci/config.yml
sed -E -i '' "s#(&server-ignore-branch) placeholder_branch_name#\1 $(GIT_BRANCH)#" .circleci/config.yml
sed -E -i '' "s#(&dp3-env) placeholder_env#\1 $(DEPLOY_ENV)#" .circleci/config.yml
@git --no-pager diff .circleci/config.yml
@echo "Please make sure to commit the changes in .circleci/config.yml in order to have CircleCI deploy $(GIT_BRANCH) to the Non-ATO $(DEPLOY_ENV) environment."

.PHONY: nonato_deploy_restore
nonato_deploy_restore: ## Restore placeholders in config after deploy to a non-ATO env
sed -E -i '' "s#(&dp3-branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .circleci/config.yml
sed -E -i '' "s#(&integration-ignore-branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .circleci/config.yml
sed -E -i '' "s#(&integration-mtls-ignore-branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .circleci/config.yml
sed -E -i '' "s#(&client-ignore-branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .circleci/config.yml
sed -E -i '' "s#(&server-ignore-branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .circleci/config.yml
sed -E -i '' "s#(&dp3-env) (exp|loadtest|demo)#\1 placeholder_env#" .circleci/config.yml

#
# ----- END NON-ATO DEPLOYMENT TARGETS -----
#


#
# ----- START NON-ATO DEPLOYMENT TARGETS -----
#

.PHONY: nonato_gitlab_deploy_prepare
nonato_gitlab_deploy_prepare: ## Replace placeholders in config to deploy to a non-ATO env. Requires DEPLOY_ENV to be set to exp, loadtest, or demo.
ifeq ($(DEPLOY_ENV), exp)
@echo "Preparing for deploy to experimental"
else ifeq ($(DEPLOY_ENV), loadtest)
Expand All @@ -1263,10 +1225,10 @@ endif
sed -E -i '' "s#(&server_ignore_branch) placeholder_branch_name#\1 $(GIT_BRANCH)#" .gitlab-ci.yml
sed -E -i '' "s#(&dp3_env) placeholder_env#\1 $(DEPLOY_ENV)#" .gitlab-ci.yml
@git --no-pager diff .gitlab-ci.yml
@echo "Please make sure to commit the changes in .gitlab-ci.yml in order to have CircleCI deploy $(GIT_BRANCH) to the Non-ATO $(DEPLOY_ENV) environment."
@echo "Please make sure to commit the changes in .gitlab-ci.yml in order to have Gitlab deploy $(GIT_BRANCH) to the Non-ATO $(DEPLOY_ENV) environment."

.PHONY: nonato_gitlab_deploy_restore
nonato_gitlab_deploy_restore: ## Restore placeholders in config after deploy to a non-ATO env
.PHONY: nonato_deploy_restore
nonato_deploy_restore: ## Restore placeholders in config after deploy to a non-ATO env
sed -E -i '' "s#(&dp3_branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .gitlab-ci.yml
sed -E -i '' "s#(&integration_ignore_branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .gitlab-ci.yml
sed -E -i '' "s#(&integration_mtls_ignore_branch) $(GIT_BRANCH)#\1 placeholder_branch_name#" .gitlab-ci.yml
Expand Down
1 change: 1 addition & 0 deletions migrations/app/migrations_manifest.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1084,3 +1084,4 @@
20250116200912_disable_homesafe_stg_cert.up.sql
20250120144247_update_pricing_proc_to_use_110_percent_weight.up.sql
20250121153007_update_pricing_proc_to_handle_international_shuttle.up.sql
20250123173216_add_destination_queue_db_func_and_gbloc_view.up.sql
Loading
Loading