Skip to content

Deploy OpenShare Engine on AWS

OpenShare Engine is Saga IT’s maintained build of the Open Integration Engine, a healthcare integration engine for HL7 v2, FHIR, DICOM and X12. AWS Marketplace offers it as two free AMIs that run in your own AWS account:

Both run engine 4.7, with Java 21 bundled and the signed OpenShare admin plugin preinstalled.

The software is free. You pay AWS only for the resources you launch: the instance, its EBS volume and network traffic. The engine’s source code is public under the MPL 2.0 at SagaHealthcareIT/open-integration-engine.

You need:

  • An AWS account, with permission to subscribe to AWS Marketplace products and to launch EC2 instances and create security groups.
  • The public address range of the network you will administer the engine from, in CIDR form. A single address is written as 203.0.113.10/32.
  • Windows: an IAM role for the instance with the AmazonSSMManagedInstanceCore policy, so you can read the initial password with Systems Manager Run Command. Without it, you need RDP and an EC2 key pair instead.
  • Linux: an EC2 key pair, if you want SSH.
  • Optional: a launch document from the OpenShare console, to register the engine with OpenShare (see Optional: register with OpenShare).
  • Optional: your own PostgreSQL, SQL Server, MySQL or Oracle database that the instance can reach.
Setting What to choose Default
Name A name for this engine None
AMI The OpenShare Engine AMI that the listing selected. Leave it as set The current version
Instance type t3.large (2 vCPUs, 8 GB) suits most single-site engines. t3 types are burstable: under sustained load they bill extra CPU credits (Unlimited mode, the default) or slow down (Standard mode). For sustained production load, use a fixed-performance type such as m5. At first boot the engine sets its Java heap to half the instance’s memory, up to 8 GB t3.large
Key pair Linux: the key pair for SSH as user ubuntu. Windows: the key pair that decrypts the Windows Administrator password for RDP. You don’t need either to sign in to the engine None
Network settings The VPC and subnet the engine should live in. Give the instance a public IP address to reach it over the internet. Without one (over VPN or Direct Connect), OpenShare registration needs outbound internet access, for example through a NAT gateway Your default VPC
Security group Let the launch page create a security group from the seller’s settings. It allows TCP 8443 only, from 0.0.0.0/0: change the source to your administration network’s range TCP 8443 from anywhere
Storage The embedded database and logs live on this volume, so size it for your message volume and retention 30 GB gp3 (Linux), 50 GB gp3 (Windows)
IAM instance profile (Advanced details) Windows: the role with AmazonSSMManagedInstanceCore. Linux: optional None
Metadata version (Advanced details) Leave it on V2 only (token required). The AMI requires IMDSv2, and the engine reads its user data that way V2 only
User data (Advanced details) See Optional: register with OpenShare and Optional: your own database. Paste the document as it is, and leave User data has already been base64 encoded unticked. Read only at first boot Empty

In the commands on this page, replace INSTANCE_ID with the instance’s ID, SG_ID with its security group’s ID, and PUBLIC_DNS with its public DNS name or address.

Port Used for Open after launch?
TCP 8443 The engine’s web interface and API, over HTTPS Only from the security group’s source. Narrow it to your own range (step 3)
TCP 22 (Linux) or TCP 3389 (Windows) SSH or RDP No. Add a rule from your own range if you want it. You don’t need either to get started
Your channel ports, for example an MLLP listener Your interfaces Never opened for you. Add rules yourself (step 6)
TCP 80 and 443 Not used by the engine Don’t open them
TCP 8080 The engine’s plain-HTTP port Don’t open it

The engine’s outbound traffic (to your systems and, if you registered it, to OpenShare over HTTPS) uses the security group’s outbound rules, which allow all outbound traffic unless you change them.

On Windows, Windows Firewall stays on. The image allows 8443 and 8080 through it. Any other port needs a Windows Firewall rule as well as a security group rule.

  1. Open the listing for Linux or Windows and select View purchase options.
  2. Subscribe. The software is free, so the subscription adds no software charge.
  3. Launch the instance with the settings above.
  4. Wait for the instance to start. After it is running, the engine needs a few more minutes for its first start, and longer on Windows.

Each instance generates a random password for the engine’s admin user at first boot. There is no default password.

The password is printed to the instance’s console output, in the “OpenShare Engine initial login” block:

  • EC2 console: select the instance, then Actions, Monitor and troubleshoot, Get system log.

  • AWS CLI:

    Terminal window
    aws ec2 get-console-output --instance-id INSTANCE_ID --latest --query Output --output text

    This is the instance’s console output, not the separate EC2 Serial Console service.

  • Over SSH: sudo cat /etc/openshare/initial-credentials (readable by root only).

Step 3: Open port 8443 to your own network

Section titled “Step 3: Open port 8443 to your own network”

If you changed the security group’s 8443 source to your own range at launch, skip this. Otherwise allow 8443 from your range and remove the rule for 0.0.0.0/0:

Terminal window
aws ec2 authorize-security-group-ingress --group-id SG_ID --protocol tcp --port 8443 --cidr YOUR_RANGE
aws ec2 revoke-security-group-ingress --group-id SG_ID --protocol tcp --port 8443 --cidr 0.0.0.0/0

The engine has no sign-in page of its own in the browser. There are two ways to manage it.

From any browser, through OpenShare. Register the engine with OpenShare, Saga IT’s online service, when you launch it; see Optional: register with OpenShare. Registering is free and needs an OpenShare account. Then, in the OpenShare console, select Connect on the server and sign in as admin with the password from step 2. To register an engine that is already running, sign in standalone first, then follow Adding a server.

Standalone, with the desktop OpenShare Administrator. An Administrator launcher opens it:

  1. Browse to https://PUBLIC_DNS:8443 to check that the engine answers. The instance ships a self-signed certificate, so your browser warns on the first visit. The page shows Service Available and the address for an Administrator launcher.

    The engine's page on port 8443: the OpenShare logo, Service Available, The backend service is running, the address to point an Administrator launcher to (https://203.0.113.25:8443/webstart.jnlp), a link to launcher options and a Go to API button
  2. Install the OpenShare Administrator Launcher on a Windows or Linux computer; there is no macOS version. An engine you connect to directly needs no OpenShare account: download the launcher from the OpenShare Engine releases on GitHub. If you already use another Administrator launcher, give it the address the page shows.

  3. In the launcher, choose Add engine…, give the engine a name and enter PUBLIC_DNS:8443. Then select it and choose Connect.

  4. The launcher shows the certificate’s SHA-256 fingerprint. Before you choose Trust certificate, compare it with the engine’s:

    • Linux, over SSH (step 5):

      Terminal window
      openssl s_client -connect localhost:8443 </dev/null 2>/dev/null | openssl x509 -noout -fingerprint -sha256
    • Windows, through Run Command or an RDP session, in PowerShell, with the engine’s bundled Java:

      Terminal window
      & 'C:\Program Files\OpenShareEngine\jre\bin\keytool.exe' -printcert -sslserver localhost:8443 | Select-String 'SHA256:'
  5. Sign in to the OpenShare Administrator as admin with the password from step 2.

Either way, once you’re signed in:

  1. Change the password right away. The engine does not force a change at first sign-in. The new password needs at least 15 characters, with an upper-case letter, a lower-case letter, a digit and a symbol.

  2. Delete the file that holds the initial password:

    • Linux: sudo rm /etc/openshare/initial-credentials
    • Windows: Remove-Item C:\ProgramData\OpenShare\initial-credentials.txt

    On Linux the console output keeps the initial password until newer output replaces it. It no longer works once you have changed it.

Five failed sign-ins lock the account for an hour. For production use, install your own TLS certificate in place of the self-signed one.

Allow TCP 22 from your own range, then:

Terminal window
ssh -i KEY_FILE.pem ubuntu@PUBLIC_DNS
sudo systemctl status oieservice
sudo tail -n 100 /opt/OpenShareEngine/logs/mirth.log

The engine is healthy when oieservice is active (running) and https://PUBLIC_DNS:8443 shows Service Available.

Each listener channel needs its own inbound rule, from your partner’s range only. For example, for an MLLP listener on 6661:

Terminal window
aws ec2 authorize-security-group-ingress --group-id SG_ID --protocol tcp --port 6661 --cidr PARTNER_RANGE

On Windows, also allow the port through Windows Firewall:

Terminal window
New-NetFirewallRule -DisplayName 'OpenShare MLLP 6661' -Direction Inbound -Protocol TCP `
-LocalPort 6661 -RemoteAddress PARTNER_RANGE -Action Allow

OpenShare is a separate online service from Saga IT. Registering with it is free and optional, and the engine works fully without it. It needs an OpenShare account and acceptance of the OpenShare terms. The service stores no patient data.

  1. In the OpenShare console, add a server. In its setup dialog, choose Cloud image, then Generate launch document, and copy the document. It is valid until the time shown under it.
  2. Paste it into User data when you launch the instance.
  3. At first boot the engine registers itself. It then connects out to OpenShare over HTTPS. No inbound port is needed.
  4. When the console shows the server as registered, clear the instance’s user data. It holds a single-use token, and any process on the instance can read it. EC2 changes user data only while the instance is stopped: stop the instance, choose Actions, Instance settings, Edit user data, clear the field, save, and start the instance again. Unless the instance has an Elastic IP address, its public address changes when it stops and starts.

The document is read only at first boot. Adding it to an existing instance has no effect. The first-boot log says what became of it: the console output on Linux, C:\ProgramData\OpenShare\firstboot.log on Windows.

  • The engine starts but never shows as registered. The engine ignored the document, for example because it had expired or was pasted incompletely. Register the running engine from the OpenShare console instead (see Adding a server), or launch a new instance with a new document.
  • The engine does not start. The document’s database or engine settings are invalid, or the database can’t be reached. Correct the user data or the database’s network path, then stop and start the instance. First boot runs again until it succeeds.

If you leave user data empty, the engine runs standalone. You can still register it later; see Adding a server.

User data can also carry a document that points the engine at your own PostgreSQL, SQL Server, MySQL or Oracle database, alone or together with OpenShare registration. Put TLS in the JDBC URL (for PostgreSQL, sslmode=require; for SQL Server, encrypt=true). For the document format, email support@openshare.health. Without such a document, the engine uses its embedded database on the instance’s volume.

That document contains the database password. After first boot, clear the instance’s user data as described above. Anyone with permission to view the instance’s attributes in your account can read it until then: use a database account for the engine alone.

  • Operating system updates. Apply updates in a maintenance window: on Linux, sudo apt update && sudo apt upgrade; on Windows, Windows Update.
  • Backups. With the embedded database, everything is on the instance’s EBS volume. Snapshot it on a schedule, for example with Amazon Data Lifecycle Manager or AWS Backup. With your own database, back that database up as well.
  • Copies of the engine. A copy of a registered engine, such as an instance built from a snapshot of this one’s volume or launched from an AMI made from it, starts as the same OpenShare server. While the original runs, keep the copy without outbound internet access: if both reach OpenShare, both answer the same connections, and partner messages and console sessions can reach either one. To run a copy as a server of its own, see Copies of a registered engine.
  • Instance type. Stop the instance, change its type, and start it again. The Java heap was set at first boot and does not follow the new memory size: change the -Xmx line in the engine’s conf/custom.vmoptions file (/opt/OpenShareEngine/conf/ on Linux, C:\Program Files\OpenShareEngine\conf\ on Windows), then restart the engine with sudo systemctl restart oieservice (Linux) or Restart-Service oie* (Windows).
  • New engine versions. Saga IT publishes new AMI versions on AWS Marketplace. Existing instances are not updated in place. Back up the engine’s database before you move to a new version.
  • Removing the engine. Terminate the instance. Its root volume is deleted with it unless you changed that setting. Then delete the security group if nothing else uses it.

Email support@openshare.health. Include the engine version and build date, which the OpenShare Administrator shows under Other, About (or, if you can’t sign in, the whole line in the engine’s logs/mirth.log that ends “server successfully started”), the instance type and the relevant lines from that log. Never include patient data in a support request. See also Getting support.