Skip to content

Commit

Permalink
Merge branch 'hl7au:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
projkov authored Oct 25, 2024
2 parents 55dca4a + 92135ec commit a01baa4
Show file tree
Hide file tree
Showing 575 changed files with 55,127 additions and 54,482 deletions.
6 changes: 1 addition & 5 deletions .env.development
Original file line number Diff line number Diff line change
@@ -1,6 +1,2 @@
V311_VALIDATOR_URL=http://localhost/validatorapi
V400_VALIDATOR_URL=http://localhost/validatorapi
V501_VALIDATOR_URL=http://localhost/validatorapi
V610_VALIDATOR_URL=http://localhost/validatorapi
V700_BALLOT_VALIDATOR_URL=http://localhost/validatorapi
FHIR_RESOURCE_VALIDATOR_URL=http://localhost/hl7validatorapi
REDIS_URL=redis://localhost:6379/0
7 changes: 2 additions & 5 deletions .env.production
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
REDIS_URL=redis://redis:6379/0
V311_VALIDATOR_URL=http://validator-service:4567
V400_VALIDATOR_URL=http://validator-service:4567
V501_VALIDATOR_URL=http://validator-service:4567
V610_VALIDATOR_URL=http://validator-service:4567
V700_BALLOT_VALIDATOR_URL=http://validator-service:4567

FHIR_RESOURCE_VALIDATOR_URL=http://validator-api:3500
16 changes: 16 additions & 0 deletions .github/ISSUE_TEMPLATE/issue-template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
name: Issue Template
about: Provide us issues for problems and requests
title: "[ISSUE] title"
labels: ''
assignees: ''

---

Title: A brief and descriptive title for the issue.

Description: A detailed description of the issue, including:

1. Steps to reproduce the issue.
2. Expected and actual behavior.
3. Screenshots or another related information (if applicable).
165 changes: 165 additions & 0 deletions .github/workflows/k8-deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,165 @@
name: 'Inferno Deployment to K8'

on:
push:
branches:
- master
pull_request:
branches:
- master
workflow_dispatch: # Manual trigger


permissions:
id-token: write # This is required for requesting the JWT
contents: read # This is required for actions/checkout
pull-requests: write # This is required for posting the comment

jobs:
terraform-plan:
name: 'Terraform Plan'
runs-on: ubuntu-latest
outputs:
tfplanExitCode: ${{ steps.tf-plan.outputs.exitcode }}
env:
working-dir: "./infra/aws-impl"
steps:
# Checkout the repository to the GitHub Actions runner
- name: Checkout
uses: actions/checkout@v4

# Configure AWS credentials
- name: Configure aws credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::471112546300:role/inferno-github-actions-eks-role
aws-region: ap-southeast-2

# Install the latest version of the Terraform CLI
- name: Setup Terraform
uses: hashicorp/setup-terraform@v3
with:
terraform_wrapper: false

# Initialize a new or existing Terraform working directory by creating initial files, loading any remote state, downloading modules, etc.
- name: Terraform Init
run: terraform init -upgrade
working-directory: ${{ env.working-dir }}

# Checks that all Terraform configuration files adhere to a canonical format
# Will fail the build if not
- name: Terraform Format
run: terraform fmt -check
working-directory: ${{ env.working-dir }}

# Generates an execution plan for Terraform
# An exit code of 0 indicated no changes, 1 a terraform failure, 2 there are pending changes.
- name: Terraform Plan
id: tf-plan
working-directory: ${{ env.working-dir }}
run: |
export exitcode=0
terraform plan -detailed-exitcode -no-color -out main.tfplan || export exitcode=$?
echo "exitcode=$exitcode" >> $GITHUB_OUTPUT
if [ $exitcode -eq 1 ]; then
echo Terraform Plan Failed!
exit 1
else
exit 0
fi
# Save plan to artifacts
- name: Publish Terraform Plan
uses: actions/upload-artifact@v4
with:
name: tfplan
path: ${{ env.working-dir }}/main.tfplan

# Create string output of Terraform Plan
- name: Create String Output
id: tf-plan-string
working-directory: ${{ env.working-dir }}
run: |
TERRAFORM_PLAN=$(terraform show -no-color main.tfplan)
delimiter="$(openssl rand -hex 8)"
echo "summary<<${delimiter}" >> $GITHUB_OUTPUT
echo "## Terraform Plan Output" >> $GITHUB_OUTPUT
echo "<details><summary>Click to expand</summary>" >> $GITHUB_OUTPUT
echo "" >> $GITHUB_OUTPUT
echo '```terraform' >> $GITHUB_OUTPUT
echo "$TERRAFORM_PLAN" >> $GITHUB_OUTPUT
echo '```' >> $GITHUB_OUTPUT
echo "</details>" >> $GITHUB_OUTPUT
echo "${delimiter}" >> $GITHUB_OUTPUT
# Publish Terraform Plan as task summary, fails when over 7k characters
- name: Publish Terraform Plan to Task Summary
working-directory: ${{ env.working-dir }}
env:
SUMMARY: ${{ steps.tf-plan-string.outputs.summary }}
run: |
echo "$SUMMARY" >> $GITHUB_STEP_SUMMARY
# If this is a PR post the changes
- name: Push Terraform Output to PR
if: github.event_name == 'pull_request'
uses: actions/github-script@v7
env:
SUMMARY: "${{ steps.tf-plan-string.outputs.summary }}"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const body = `${process.env.SUMMARY}`;
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: body
})
terraform-apply:
name: 'Terraform Apply'
if: github.ref == 'refs/heads/master' && needs.terraform-plan.outputs.tfplanExitCode == 2
runs-on: ubuntu-latest
environment: production
needs: [terraform-plan]
env:
working-dir: "./infra/aws-impl"

steps:
# Checkout the repository to the GitHub Actions runner
- name: Checkout
uses: actions/checkout@v4

# Configure AWS credentials
- name: Configure aws credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::471112546300:role/inferno-github-actions-eks-role
aws-region: ap-southeast-2

# Install the latest version of Terraform CLI and configure the Terraform CLI configuration file with a Terraform Cloud user API token
- name: Setup Terraform
uses: hashicorp/setup-terraform@v3
with:
terraform_wrapper: false

# Initialize a new or existing Terraform working directory by creating initial files, loading any remote state, downloading modules, etc.
- name: Terraform Init
run: terraform init -upgrade
working-directory: ${{ env.working-dir }}

# Download saved plan from artifacts
- name: Download Terraform Plan
uses: actions/download-artifact@v4
with:
name: tfplan
path: ${{ env.working-dir }}

# Terraform Apply
- name: Terraform Apply
run: terraform apply -auto-approve main.tfplan
working-directory: ${{ env.working-dir }}
8 changes: 8 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ AllCops:
- 'lib/au_core_test_kit/fhir_resource_navigation.rb'
- 'lib/au_core_test_kit/date_search_validation.rb'
- 'lib/au_core_test_kit/custom_groups/v0.3.0-ballot/profile_support_test.rb'
- 'lib/au_core_test_kit/generated/v0.3.0-ballot/au_core_test_suite.rb'
- 'lib/au_core_test_kit/generator/multiple_or_search_test_generator.rb'
- 'lib/au_core_test_kit/generator/multiple_and_search_test_generator.rb'
- 'lib/au_core_test_kit/generator/chain_search_test_generator.rb'
- 'lib/au_core_test_kit/generator/special_identifier_search_test_generator.rb'
- 'lib/au_core_test_kit/special_identifier_search_test.rb'
- 'lib/au_core_test_kit/generator/special_identifiers_chain_search_test_generator.rb'
- 'lib/au_core_test_kit/generator/include_search_test_generator.rb'
Style/Documentation:
Enabled: false
Layout/LineLength:
Expand Down
117 changes: 115 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,119 @@
# 0.0.1
# 0.0.15
* Add conditional/basic skip with a message by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/209
* Update _include tests by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/212
* Add separate _include tests by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/217

# 0.0.14
## AU Core Test Kit changes
* Update target_profile modification for au-specimen by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/194
* Add missing data tests by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/195
* Add validator messages filter by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/202
## Documentation
* Update us_core_diffs.md by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/198
## Other
* remove old manifest implementation and update ngnix dependency by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/188

# 0.0.13
## AU Core Test Kit changes
* AU Core 1.0.0-preview

# 0.0.12
## AU Core Test Kit changes
* Add auto _count search parameter by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/184
* Add an ability to activate read for first _id search automatically by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/183
* Update description for the CapabilityStatement group by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/182
* Update group description for Practitioner, PractitionerRole, Location, and Organization by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/181

# 0.0.11
## AU Core Test Kit changes
* Update 0.4.0-preview to 0.4.1-preview by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/171
* Use gem as validation test suite by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/168
* Add an ability to run the first search for Patient as read test by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/174
* Add optional _count search parameter by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/176
* Update test suite sources by @projkov https://github.com/hl7au/au-fhir-core-inferno/pull/162, https://github.com/hl7au/au-fhir-core-inferno/pull/175, https://github.com/hl7au/au-fhir-core-inferno/pull/177
## Documentation
* Update prerequisites by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/169
## Other
* Allow direct manifests to use rds during db migration by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/173
* Implement Helm Chart for AU FHIR Inferno with Optional NGINX Ingress and Bitnami PostgreSQL by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/167

# 0.0.10
* Add new default patient id by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/146
* Update read tests to use Practitioner, PractitionerRole, Location, Organization by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/157
* Add test group to validate any resource by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/156
* Add default values for diagnostic result Observation by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/160
* Ingress update: remove validator path, update validatorapi path by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/145
* Convert postgres deployment to statefulset, add liveness and readiness probe by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/149

# 0.0.9
* Fix search for the extension value by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/139
* Fix multiple date search by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/141
* Migrate to the HL7 official validator by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/118

# 0.0.8
* AU Core 0.4.0-preview
* Minor changes

# 0.0.7
* Add search by practitioner id for PractitionerRole test by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/132
* Generate test kit source files @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/133

# 0.0.6
* Update narrative for validation tests by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/122
* Update narrative for the Capability Statement group by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/123
* Add check for support XML by Capability Statement by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/124
* Change the default URL by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/127
* Handle special case for combo searches by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/128
* Add prefix with information about expectaction by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/130
* Generate test kit source files @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/131, https://github.com/hl7au/au-fhir-core-inferno/pull/119, https://github.com/hl7au/au-fhir-core-inferno/pull/129, https://github.com/hl7au/au-fhir-core-inferno/pull/125

# 0.0.5
* Add reporting issues section to the README by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/109
* Update search-params file to fix problems with searchDefinitions by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/111
* Generate test kit source files @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/112

# 0.0.4
* Regenerate test kit source files after updating the IG in https://github.com/hl7au/au-fhir-core-inferno/pull/107

# 0.0.3
* 62 add multiple and by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/75
* 48 add missing comparators by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/76
* WIP: Add chained search for patient:Patient.identifier by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/82
* Change tx server from test to dev by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/68
* Merge new auto generated tests by @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/83
* Fix optional? method by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/84
* Merge new auto generated tests by @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/85
* 80 ihi dva chained by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/86
* Merge new auto generated tests by @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/87
* Add search for Practitioner IHI-I by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/88
* Merge new auto generated tests by @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/89
* Merge new auto generated tests by @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/90
* Fix search by identifier by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/104
* Merge new auto generated tests by @github-actions in https://github.com/hl7au/au-fhir-core-inferno/pull/105

# 0.0.2
* Spec tests by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/31
* Summary generator update by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/32
* Add generate-tests action by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/37
* Add rubocop as CI step by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/39
* Update files by rubocop except generated by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/51
* Update test files by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/53
* Add build and release pipeline by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/55
* CICD: Implement Terraform Workflow for EKS Deployment by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/41
* Add auth header and value inputs by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/66
* Remove Location and PractitionerRole from special cases by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/67

# 0.0.1
* Tests are available for the AU Core 0.3.0-ballot.
* Searching tests
* Reading tests
* Resource validation
* Resource validation

* Update summary generator by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/10
* Use terminology server url from the ENV by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/11
* EKS-Specific Terraform Implementation for Inferno App Deployment by @KyleOps in https://github.com/hl7au/au-fhir-core-inferno/pull/13
* 0.3.0 ballot march by @ir4y in https://github.com/hl7au/au-fhir-core-inferno/pull/17
* Add may search params and combo search params by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/27
* Fix descr urls by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/23
* Add PSQL as docker compose service by @projkov in https://github.com/hl7au/au-fhir-core-inferno/pull/26

2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ end
gem 'pg', '~> 1.5'
gem 'rubocop', '~> 1.63.2'
gem 'rubocop-erb', '~> 0.3.0'
gem 'sqlite3', '~> 1.4'
gem 'validation_test_kit', github: 'beda-software/validation-test-kit', ref: '3438159ae5860216d37c559725fbfdc316ad745c'
Loading

0 comments on commit a01baa4

Please sign in to comment.