Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
7 changes: 6 additions & 1 deletion .github/actions/build-proxies/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,12 @@ runs:
working-directory: .
shell: bash
run: |
make build-json-oas-spec APIM_ENV=dev
if [ -z $PR_NUMBER ]
then
make build-json-oas-spec APIM_ENV=dev
else
make build-json-oas-spec APIM_ENV=dev-pr
fi

- name: Set target
shell: bash
Expand Down
1 change: 1 addition & 0 deletions .tool-versions
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ terraform 1.10.1
terraform-docs 0.19.0
trivy 0.61.0
vale 3.6.0
poetry 2.1.4

# ==============================================================================
# The section below is reserved for Docker image versions.
Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,16 @@ set-access: guard-APIM_ENV
envsubst '$${ACCESS}' \
< specification/api/components/x-nhsd-apim/access-template.yml > specification/api/components/x-nhsd-apim/access.yml

set-security: guard-APIM_ENV
@ SECURITY=security-$$APIM_ENV.yml \
envsubst '$${SECURITY}' \
< specification/api/components/security/security-template.yml > specification/api/components/security/security.yml

construct-spec: guard-APIM_ENV
$(MAKE) set-target APIM_ENV=$$APIM_ENV
$(MAKE) set-access APIM_ENV=$$APIM_ENV
$(MAKE) set-security APIM_ENV=$$APIM_ENV



build-json-oas-spec: guard-APIM_ENV
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
app-level0: []
1 change: 1 addition & 0 deletions specification/api/components/security/security-dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
app-level3: [ ]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
app-level0: []
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
$ref: $SECURITY
1 change: 1 addition & 0 deletions specification/api/components/security/security.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
$ref: security-dev-pr.yml
3 changes: 3 additions & 0 deletions specification/api/components/x-nhsd-apim/access-dev-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- title: Application Restricted
grants:
app-level0: []
1 change: 0 additions & 1 deletion specification/api/components/x-nhsd-apim/access-dev.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
- title: Application Restricted
grants:
app-level0: []
app-level3: []
2 changes: 1 addition & 1 deletion specification/api/components/x-nhsd-apim/access.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
$ref: access-sandbox.yml
$ref: access-dev-pr.yml
7 changes: 7 additions & 0 deletions specification/api/components/x-nhsd-apim/target-dev-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
type: external
healthcheck: /_status
url: https://suppliers.dev.nhsnotify.national.nhs.uk
security:
type: apikey
header: Authorization
secret: nhs-notify-supplier-key
2 changes: 1 addition & 1 deletion specification/api/components/x-nhsd-apim/target.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
$ref: target-sandbox.yml
$ref: target-dev-pr.yml
7 changes: 4 additions & 3 deletions specification/api/notify-supplier-phase1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ info:
This specification represents the in-development 'next' version of the API schema
and should be treated as unstable.
security:
- app-level0: [ ]
- $ref: 'components/security/security.yml'
paths:
/letters:
parameters:
Expand Down Expand Up @@ -55,10 +55,11 @@ paths:
$ref: 'components/endpoints/headDataId.yml'
components:
securitySchemes:
nhs-login-p0:
$ref: https://proxygen.ptl.api.platform.nhs.uk/components/securitySchemes/nhs-login-p0
app-level3:
$ref: https://proxygen.ptl.api.platform.nhs.uk/components/securitySchemes/app-level3
app-level0:
$ref: https://proxygen.ptl.api.platform.nhs.uk/components/securitySchemes/app-level0

tags:
- name: letter
description: ''
Expand Down
Loading