From 16ab89fa365b0828df133ffacb0a198d1ae6abd2 Mon Sep 17 00:00:00 2001 From: George Hudson Date: Fri, 29 Sep 2023 08:54:24 -0600 Subject: [PATCH] readded clam av nginx router url to manifest and setting network policies in the deploy-backend.sh script --- scripts/deploy-backend.sh | 7 +++++++ tdrs-backend/manifest.yml | 3 +++ 2 files changed, 10 insertions(+) diff --git a/scripts/deploy-backend.sh b/scripts/deploy-backend.sh index f3ed5941d..bc1b88545 100755 --- a/scripts/deploy-backend.sh +++ b/scripts/deploy-backend.sh @@ -107,6 +107,13 @@ update_backend() # Add network policy to allow frontend to access backend cf add-network-policy "$CGAPPNAME_FRONTEND" "$CGAPPNAME_BACKEND" --protocol tcp --port 8080 + if ["$CF_SPACE" = "tanf-prod" ]; then + # Add network policy to allow backend to access tanf-prod services + cf add-network-policy "$CGAPPNAME_BACKEND" clamav-rest --protocol tcp --port 9000 + else + cf add-network-policy "$CGAPPNAME_BACKEND" tdp-clamav-nginx-$env --protocol tcp --port 9000 + fi + cd .. } diff --git a/tdrs-backend/manifest.yml b/tdrs-backend/manifest.yml index bc059b375..473c6d387 100755 --- a/tdrs-backend/manifest.yml +++ b/tdrs-backend/manifest.yml @@ -6,3 +6,6 @@ applications: disk_quota: 2G docker: image: ((docker-backend)) + env: + AV_SCAN_URL: http://((cf-space))-clamav-rest.apps.internal:9000/scan + \ No newline at end of file