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

Prmdr 168 Back Channel Logout #103

Merged
merged 37 commits into from
Oct 20, 2023
Merged
Show file tree
Hide file tree
Changes from 32 commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
64e9a94
BCL handler and test files
thisusernameisnowtaken Oct 11, 2023
6809cf5
Use CIS2 public key to validate logout token
thisusernameisnowtaken Oct 11, 2023
1dd4a47
Change error messages to JSON according to CIS2 spec
thisusernameisnowtaken Oct 11, 2023
e42d9d0
Reduce duplicate code
thisusernameisnowtaken Oct 11, 2023
a6150f5
Use CIS2s published key to validate the logout token
thisusernameisnowtaken Oct 12, 2023
cdf9c67
Merge branch 'main' into prmdr-168
AlexHerbertNHS Oct 17, 2023
6c76d6c
Add new lambda to sandbox deployment workflow
thisusernameisnowtaken Oct 18, 2023
4e2d7a7
Correction to file name
thisusernameisnowtaken Oct 18, 2023
dc59d56
Correction to file name two
thisusernameisnowtaken Oct 18, 2023
c17617a
Pwease work
thisusernameisnowtaken Oct 18, 2023
fe72461
Deploy new lambda for other workflows
thisusernameisnowtaken Oct 18, 2023
f99967b
Alter imports on BCL handler
thisusernameisnowtaken Oct 18, 2023
93ffe89
Extract request body before looking for token
thisusernameisnowtaken Oct 19, 2023
f151bd9
PRMDR-168
AlexHerbertNHS Oct 19, 2023
e539d1b
Code tidy up
thisusernameisnowtaken Oct 19, 2023
9fdf02f
PRMDR-168
AlexHerbertNHS Oct 19, 2023
b72d5c6
Return POST response for BCL
thisusernameisnowtaken Oct 19, 2023
7894b16
Issue deconstructing request
thisusernameisnowtaken Oct 19, 2023
06f4b3f
Issue deconstructing request
thisusernameisnowtaken Oct 19, 2023
b5cffb9
PRMDR-168
AlexHerbertNHS Oct 19, 2023
089a9f1
Merge remote-tracking branch 'origin/prmdr-168' into prmdr-168
AlexHerbertNHS Oct 19, 2023
ba0eeea
Issue deconstructing request
thisusernameisnowtaken Oct 19, 2023
3aa6319
PRMDR-168
AlexHerbertNHS Oct 19, 2023
eb5bcc7
Fix divergent branches
thisusernameisnowtaken Oct 19, 2023
0678303
Fix divergent branches
thisusernameisnowtaken Oct 19, 2023
cfb5160
PRMDR-168
AlexHerbertNHS Oct 19, 2023
efef823
Merge remote-tracking branch 'origin/prmdr-168' into prmdr-168
AlexHerbertNHS Oct 19, 2023
3788563
PRMDR-168
AlexHerbertNHS Oct 19, 2023
1a85a70
PRMDR-168
AlexHerbertNHS Oct 19, 2023
1f8cab1
PRMDR-168
AlexHerbertNHS Oct 19, 2023
e61a571
PRMDR-168
AlexHerbertNHS Oct 19, 2023
0cd1cc8
PRMDR-168
AlexHerbertNHS Oct 19, 2023
e1906bb
PRMDR-168
AlexHerbertNHS Oct 20, 2023
8ea45f6
PRMDR-168
AlexHerbertNHS Oct 20, 2023
cc6485c
PRMDR-168
AlexHerbertNHS Oct 20, 2023
99c98ac
PRMDR-168
AlexHerbertNHS Oct 20, 2023
8df53f5
PRMDR-168
AlexHerbertNHS Oct 20, 2023
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
65 changes: 51 additions & 14 deletions .github/workflows/full-lambdas-dispatch-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
repository_dispatch:
types: lambda-dispatch-deploy


permissions:
pull-requests: write
id-token: write # This is required for requesting the JWT
Expand All @@ -13,8 +12,7 @@ permissions:
jobs:
view_action_parameters:
runs-on: ubuntu-latest
steps:

steps:
- name: Display client passed variables
run: |
echo Environement Equals: ${{ github.event.client_payload.environment }}
Expand All @@ -37,9 +35,9 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Make virtual environment
run: |
run: |
make env

- name: Start virtual environment
run: |
source ./lambdas/venv/bin/activate
Expand All @@ -58,7 +56,7 @@ jobs:
environment: ${{ github.event.client_payload.environment }}
strategy:
matrix:
python-version: [ "3.11" ]
python-version: ["3.11"]
needs: ["python_lambdas_test"]

steps:
Expand All @@ -71,7 +69,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Make virtual environment
run: |
run: |
make env

- name: Configure AWS Credentials
Expand All @@ -84,21 +82,21 @@ jobs:
- name: Create release package for Create Document Reference
run: |
make lambda_name=create_document_reference_handler zip

- name: Upload Lambda Function for CreateDocRefLambda
uses: appleboy/lambda-action@master
with:
aws_region: ${{ vars.AWS_REGION }}
function_name: ${{ github.event.client_payload.sandbox }}_CreateDocRefLambda
zip_file: package_lambdas_create_document_reference_handler.zip

python_deploy_search_patient_details_lambda:
runs-on: ubuntu-latest
environment: ${{ github.event.client_payload.environment }}
strategy:
matrix:
python-version: [ "3.11" ]
needs: [ "python_lambdas_test" ]
python-version: ["3.11"]
needs: ["python_lambdas_test"]

steps:
- name: Checkout
Expand Down Expand Up @@ -138,8 +136,8 @@ jobs:
environment: ${{ github.event.client_payload.environment }}
strategy:
matrix:
python-version: [ "3.11" ]
needs: [ "python_lambdas_test" ]
python-version: ["3.11"]
needs: ["python_lambdas_test"]

steps:
- name: Checkout
Expand Down Expand Up @@ -211,4 +209,43 @@ jobs:
with:
aws_region: ${{ vars.AWS_REGION }}
function_name: ${{ github.event.client_payload.sandbox }}_LloydGeorgeStitchLambda
zip_file: package_lambdas_lloyd_george_record_stitch_handler.zip
zip_file: package_lambdas_lloyd_george_record_stitch_handler.zip

python_deploy_back_channel_logout_lambda:
runs-on: ubuntu-latest
environment: development
needs: ["python_lambdas_test"]
strategy:
matrix:
python-version: ["3.11"]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Make virtual environment
run: |
make env

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v2
with:
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE }}
role-skip-session-tagging: true
aws-region: ${{ vars.AWS_REGION }}

- name: Create release package for Back Channel Logout Lambda
run: |
make lambda_name=back_channel_logout_handler zip

- name: Upload Lambda Function for Back Channel Logout Lambda
uses: appleboy/lambda-action@master
with:
aws_region: ${{ vars.AWS_REGION }}
function_name: ${{ github.event.inputs.sandboxWorkspace}}_BackChannelLogoutHandler
zip_file: package_lambdas_back_channel_logout_handler.zip
64 changes: 50 additions & 14 deletions .github/workflows/lambdas-deploy-feature-to-sandbox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Make virtual environment
run: |
run: |
make env

- name: Start virtual environment
run: |
source ./lambdas/venv/bin/activate
Expand All @@ -58,7 +58,7 @@ jobs:
environment: development
strategy:
matrix:
python-version: [ "3.11" ]
python-version: ["3.11"]
needs: ["python_lambdas_test"]

steps:
Expand All @@ -73,7 +73,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Make virtual environment
run: |
run: |
make env

- name: Configure AWS Credentials
Expand All @@ -86,21 +86,21 @@ jobs:
- name: Create release package for Create Document Reference
run: |
make lambda_name=create_document_reference_handler zip

- name: Upload Lambda Function for CreateDocRefLambda
uses: appleboy/lambda-action@master
with:
aws_region: ${{ vars.AWS_REGION }}
function_name: ${{ github.event.inputs.sandboxWorkspace}}_CreateDocRefLambda
zip_file: package_lambdas_create_document_reference_handler.zip

python_deploy_search_patient_details_lambda:
runs-on: ubuntu-latest
environment: development
strategy:
matrix:
python-version: [ "3.11" ]
needs: [ "python_lambdas_test" ]
python-version: ["3.11"]
needs: ["python_lambdas_test"]

steps:
- name: Checkout
Expand Down Expand Up @@ -140,8 +140,8 @@ jobs:
environment: development
strategy:
matrix:
python-version: [ "3.11" ]
needs: [ "python_lambdas_test" ]
python-version: ["3.11"]
needs: ["python_lambdas_test"]

steps:
- name: Checkout
Expand Down Expand Up @@ -254,7 +254,6 @@ jobs:
function_name: ${{ github.event.inputs.sandboxWorkspace}}_LoginRedirectHandler
zip_file: package_lambdas_login_redirect_handler.zip


python_deploy_authoriser_lambda:
runs-on: ubuntu-latest
environment: test
Expand Down Expand Up @@ -294,7 +293,6 @@ jobs:
function_name: ${{ github.event.inputs.sandboxWorkspace}}_AuthoriserLambda
zip_file: package_lambdas_authoriser_handler.zip


python_deploy_token_request_lambda:
runs-on: ubuntu-latest
environment: test
Expand Down Expand Up @@ -411,7 +409,6 @@ jobs:
function_name: ${{ github.event.inputs.sandboxWorkspace}}_LloydGeorgeStitchLambda
zip_file: package_lambdas_lloyd_george_record_stitch_handler.zip


python_deploy_bulk_upload_metadata_lambda:
runs-on: ubuntu-latest
environment: development
Expand Down Expand Up @@ -488,4 +485,43 @@ jobs:
with:
aws_region: ${{ vars.AWS_REGION }}
function_name: ${{ github.event.inputs.sandboxWorkspace}}_BulkUploadLambda
zip_file: package_lambdas_bulk_upload_handler.zip
zip_file: package_lambdas_bulk_upload_handler.zip

python_deploy_back_channel_logout_lambda:
runs-on: ubuntu-latest
environment: development
needs: ["python_lambdas_test"]
strategy:
matrix:
python-version: ["3.11"]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Make virtual environment
run: |
make env

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v2
with:
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE }}
role-skip-session-tagging: true
aws-region: ${{ vars.AWS_REGION }}

- name: Create release package for Back Channel Logout Lambda
run: |
make lambda_name=back_channel_logout_handler zip

- name: Upload Lambda Function for Back Channel Logout Lambda
uses: appleboy/lambda-action@master
with:
aws_region: ${{ vars.AWS_REGION }}
function_name: ${{ github.event.inputs.sandboxWorkspace}}_BackChannelLogoutHandler
zip_file: package_lambdas_back_channel_logout_handler.zip
Loading
Loading