@medplum/agent 2.1.19 → 2.1.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -9,28 +9,35 @@ On-prem agent for device connectivity.
9
9
 
10
10
  ## Building
11
11
 
12
- Build everything:
12
+ Published releases are built using Github Actions. See the [installer build script](../../scripts/build-agent-installer.sh) for details.
13
13
 
14
- ```bash
15
- npm run build:all
16
- ```
14
+ The following tools are used to build the agent:
17
15
 
18
- Or, build individual components:
16
+ - [Node.js](https://nodejs.org/en/)
17
+ - [Vercel pkg](https://github.com/vercel/pkg) to build the `.exe` file
18
+ - [NSIS](https://nsis.sourceforge.io/) to build the installer
19
+ - [Shawl](https://github.com/mtkennerly/shawl) for the Microsoft Windows service wrapper
20
+ - [JSign](https://ebourg.github.io/jsign/) to sign the executable files
19
21
 
20
- Build the JS output:
22
+ The following environment variables are required:
21
23
 
22
- ```bash
23
- npm run build
24
- ```
24
+ - `SM_HOST` - DigiCert Signing Manager host
25
+ - `SM_API_KEY` - DigiCert Signing Manager API key
26
+ - `SM_CLIENT_CERT_FILE_BASE64` - DigiCert Signing Manager client certificate file (base64 encoded)
27
+ - `SM_CLIENT_CERT_PASSWORD` - DigiCert Signing Manager client certificate password
28
+ - `SM_CERT_ALIAS` - DigiCert Signing Manager certificate alias
25
29
 
26
- Build the `.exe` file using [Vercel `pkg`](https://github.com/vercel/pkg):
30
+ The `SM_CLIENT_CERT_FILE_BASE64` environment variable can be generated from the certificate file:
27
31
 
28
32
  ```bash
29
- npm run build:exe
33
+ base64 Certificate_pkcs12.p12
30
34
  ```
31
35
 
32
- Build the installer using [NSIS](https://nsis.sourceforge.io/) (requires `makensis` on your PATH):
36
+ References:
33
37
 
34
- ```bash
35
- npm run build:installer
36
- ```
38
+ - [Sign with SMCTL](https://docs.digicert.com/en/software-trust-manager/sign-with-digicert-signing-tools/sign-with-smctl.html)
39
+ - [GitHub Actions script integration with PKCS11](https://docs.digicert.com/en/software-trust-manager/ci-cd-integrations/script-integrations/github-actions-integration-with-pkcs11.html)
40
+ - [Sign with jSign](https://docs.digicert.com/en/software-trust-manager/signing-tools/jsign.html)
41
+ - [JSign](https://ebourg.github.io/jsign/)
42
+ - [Shawl](https://github.com/mtkennerly/shawl)
43
+ - [NSIS](https://nsis.sourceforge.io/)
@@ -5209,9 +5209,8 @@ var en = class extends he {
5209
5209
  throw new Error("Missing resourceType");
5210
5210
  if (!t.id)
5211
5211
  throw new Error("Missing id");
5212
- this.invalidateSearches(t.resourceType);
5213
5212
  let i2 = await this.put(this.fhirUrl(t.resourceType, t.id), t, void 0, n);
5214
- return i2 || (i2 = t), this.cacheResource(i2), i2;
5213
+ return i2 || (i2 = t), this.cacheResource(i2), this.invalidateUrl(this.fhirUrl(t.resourceType, t.id, "_history")), this.invalidateSearches(t.resourceType), i2;
5215
5214
  }
5216
5215
  patchResource(t, n, i2, o) {
5217
5216
  return this.invalidateSearches(t), this.patch(this.fhirUrl(t, n), i2, o);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@medplum/agent",
3
- "version": "2.1.19",
3
+ "version": "2.1.20",
4
4
  "description": "Medplum Agent",
5
5
  "homepage": "https://www.medplum.com/",
6
6
  "bugs": {
@@ -19,9 +19,6 @@
19
19
  "scripts": {
20
20
  "agent": "ts-node src/main.ts",
21
21
  "build": "npm run clean && tsc && node esbuild.mjs",
22
- "build:all": "npm run build && npm run build:exe && npm run build:installer",
23
- "build:exe": "pkg ./dist/cjs/index.cjs --targets node18-win-x64 --output dist/medplum-agent-win-x64.exe --options no-warnings",
24
- "build:installer": "makensis installer.nsi",
25
22
  "clean": "rimraf dist",
26
23
  "test": "jest"
27
24
  },