Skip to content
This repository was archived by the owner on Apr 13, 2023. It is now read-only.

Commit 9fc2adb

Browse files
authored
Attribution (#54)
Changes: - All resources made from audit log or main yaml will be tagged the same - This is to assist our customers with determining the billing Tests: - yarn run release - sls deploy
1 parent 206db35 commit 9fc2adb

File tree

110 files changed

+13163
-8203
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

110 files changed

+13163
-8203
lines changed

.eslintrc.js

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0
4+
*/
5+
16
module.exports = {
27
parser: '@typescript-eslint/parser', // Specifies the ESLint parser
38
extends: [

.github/no-response.yaml

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
# SPDX-License-Identifier: Apache-2.0
4+
#
5+
16
# Configuration for probot-no-response - https://github.com/probot/no-response
27

38
# Number of days of inactivity before an Issue is closed for lack of response

.github/workflows/deploy.yml .github/workflows/deploy.yaml

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
# SPDX-License-Identifier: Apache-2.0
4+
#
5+
16
name: Unit Tests, Deploy, Integration Test
27
on:
38
push:
@@ -113,4 +118,4 @@ jobs:
113118
type: now
114119
target_branch: 'mainline'
115120
env:
116-
GITHUB_TOKEN: ${{secrets.MERGE_TOKEN}}
121+
GITHUB_TOKEN: ${{secrets.MERGE_TOKEN}}

.github/workflows/mainline-protection.yml .github/workflows/mainline-protection.yaml

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
# SPDX-License-Identifier: Apache-2.0
4+
#
5+
16
name: Mainline Protection
27
on:
38
pull_request:
@@ -10,4 +15,4 @@ jobs:
1015
name: Only create PR against develop branch, not mainline branch
1116
runs-on: ubuntu-18.04
1217
steps:
13-
- run: failing-command # An invalid bash command to trigger failure of this workflow
18+
- run: failing-command # An invalid bash command to trigger failure of this workflow

.github/workflows/unit-test.yml .github/workflows/unit-test.yaml

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#
2+
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
# SPDX-License-Identifier: Apache-2.0
4+
#
5+
16
name: Unit Test
27
on:
38
pull_request:
@@ -27,4 +32,4 @@ jobs:
2732
cd ..
2833
yarn lint
2934
- name: Unit tests
30-
run: yarn test
35+
run: yarn test

.prettierrc.js

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0
4+
*/
5+
16
module.exports = {
27
semi: true,
38
trailingComma: 'all',

NOTICE

+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
fhir-solution
12
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.

README.md

+27-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# FhirSolution MVP Installation (v 0.6.0)
1+
# FhirSolution MVP Installation (v 0.6.1)
22

33
## Introduction
44

@@ -40,6 +40,7 @@ The system architecture consists of multiple layers of AWS serverless services.
4040
This installation guide covers a basic installation on Windows, Unix-like systems, or through Docker. The Unix installation has been tested on OSX Catalina, CentOS (Amazon Linux 2), and Ubuntu (18.04 LTS), and the Windows installation has been tested on Windows Server 2019. If you encounter any problems installing in this way, please see the "Known Issues" section, or refer to the Manual Installation section.
4141

4242
### Unix Installation
43+
4344
In a Terminal application or command shell, navigate to the directory containing the package’s code.
4445

4546
Run the following lines of code:
@@ -51,52 +52,68 @@ sudo ./scripts/install.sh
5152

5253
The `sudo` command may prompt you for your password, after which installation will commence. Follow the directions in the script to finish installation. See the following section for details on optional installation settings.
5354
The `stage` and `region` values are set by default to `dev` and `us-west-2`, but they can be changed with commandline arguments as follows:
55+
5456
```sh
5557
sudo ./scripts/install.sh --region <REGION> --stage <STAGE>
5658
```
59+
5760
You can also use their abbreviations:
61+
5862
```sh
5963
sudo ./scripts/install.sh -r <REGION> -s <STAGE>
6064
```
6165

6266
### Windows Installation
67+
6368
Open Windows Powershell for AWS as Administrator, and navigate to the directory containing the package's code.
6469

6570
Run the following lines of code:
71+
6672
```sh
6773
Set-ExecutionPolicy RemoteSigned
6874
.\scripts\win_install.ps1
6975
```
76+
7077
Follow the directions in the script to finish installation. See the following section for details on optional installation settings.
7178

7279
The `stage` and `region` values are set by default to `dev` and `us-west-2`, but they can be changed with commandline arguments as follows:
80+
7381
```sh
7482
.\scripts\win_install.ps1 -Region <REGION> -Stage <STAGE>
7583
```
7684

7785
### Docker Installation
86+
7887
Install Docker (if you do not have it already) by following instructions on https://docs.docker.com/get-docker/
7988

8089
```sh
8190
docker build -t fhir-server-install -f docker/Dockerfile .
8291
docker run -it -l install-container fhir-server-install
8392
```
93+
8494
Follow the directions in the script to finish installation. See the following section for details on optional installation settings.
8595

8696
The `stage` and `region` values are set by default to `dev` and `us-west-2`, but they can be changed with commandline arguments as follows:
97+
8798
```sh
8899
docker run -it -l install-container fhir-server-install --region <REGION> --stage <STAGE>
89100
```
101+
90102
You can also use their abbreviations:
103+
91104
```sh
92105
docker run -it -l install-container fhir-server-install -r <REGION> -s <STAGE>
93106
```
107+
94108
If you would like to retrieve `Info_Output.yml` file from the container, issue the following commands:
109+
95110
```sh
96111
container_id=$(docker ps -f "label=install-container" --format "{{.ID}}")
97112
docker cp ${container_id}:/home/node/aws-fhir-solution/Info_Output.yml .
98113
```
114+
99115
To remove container:
116+
100117
```sh
101118
container_id=$(docker ps -f "label=install-container" --format "{{.ID}}")
102119
docker rm ${container_id}
@@ -105,6 +122,7 @@ docker rm ${container_id}
105122
### Optional Installation Configurations
106123

107124
#### ElasticSearch Kibana Server
125+
108126
The Kibana server allows you to explore data inside your ElasticSearch instance through a web UI. This server is automatically created if 'stage' is set to `dev`.
109127

110128
Accessing the Kibana server requires you to set up a cognito user. The installation script can help you set up a cognito user, or you can do it manually through the AWS Cognito Console.
@@ -122,12 +140,14 @@ The reason behind multiple stacks is that backup vaults can be deleted only if t
122140
These back-ups work by using tags. In the [serverless.yaml](./serverless.yaml) you can see ResourceDynamoDBTable has a `backup - daily` & `service - fhir` tag. Anything with these tags will be backed-up daily at 5:00 UTC.
123141

124142
#### Audit Log Mover
143+
125144
Audit Logs are placed into CloudWatch Logs at <CLOUDWATCH_EXECUTION_LOG_GROUP>. The Audit Logs includes information about request/responses coming to/from your API Gateway. It also includes the Cognito user that made the request.
126145

127146
In addition, if you would like to archive logs older than 7 days into S3 and delete those logs from Cloudwatch Logs, please follow the instructions below.
128147

129148
From the root directory
130-
```$sh
149+
150+
```sh
131151
cd auditLogMover
132152
serverless deploy --aws-profile <AWS PROFILE> --stage <STAGE> --region <AWS_REGION>
133153
```
@@ -141,6 +161,7 @@ serverless deploy --aws-profile <AWS PROFILE> --stage <STAGE> --region <AWS_REGI
141161
## Usage Instructions
142162

143163
### User Variables
164+
144165
After installation, all user-specific variables (such as `USER_POOL_APP_CLIENT_ID`) can be found in the `INFO_OUTPUT.yml` file. You can also retrieve these values by running `serverless info --verbose --aws-profile FHIR-Solution`.
145166
If you used a `stage` and/or `dev` values different than the default, you'll need to use the command `serverless info --verbose --aws-profile FHIR-Solution --region <REGION> --stage <STAGE>`.
146167

@@ -318,6 +339,7 @@ and execute the following command:
318339
```sh
319340
ACCESS_KEY=<ACCESS_KEY> SECRET_KEY=<SECRET_KEY> ES_DOMAIN_ENDPOINT=<ES_DOMAIN_ENDPOINT> node elasticsearch-operations.js <REGION> "<function to execute>" "<optional additional params>"
320341
```
342+
321343
These parameters can be found by checking the `INFO_OUTPUT.yml` file generated by the installation script, or by running the previously mentioned `serverless info --verbose` command.
322344

323345
## Manual Installation Prerequisites
@@ -468,12 +490,14 @@ From the command’s output note down the following data
468490
- from Stack Outputs: CloudwatchExecutionLogGroup:
469491

470492
### Deploying Audit Log Mover
493+
471494
Audit Logs are placed into CloudWatch Logs at <CLOUDWATCH_EXECUTION_LOG_GROUP>. The Audit Logs includes information about request/responses coming to/from your API Gateway. It also includes the Cognito user that made the request.
472495

473496
In addition, if you would like to archive logs older than 7 days into S3 and delete those logs from Cloudwatch Logs, please follow the instructions below.
474497

475498
From the root directory
476-
```$sh
499+
500+
```$sh
477501
cd auditLogMover
478502
yarn install
479503
serverless deploy --aws-profile <AWS PROFILE> --stage <STAGE> --region <AWS_REGION>

0 commit comments

Comments
 (0)