-
Notifications
You must be signed in to change notification settings - Fork 2
Docker Setup Requirements
The following applies to the Fall 2020 Capstone Demo. The run configuration was two dockers containing
- Parity-System
- Parity-Client
EML-CTS was run in the "host" container; in the demo this was an Ubuntu Linux system running on localhost, to which Ubuntu assigned IP address 10.0.2.15 (which appears as the command line ip address for eml-cts in the parity-client docker file).
This demo is for the experimental dev-docker branch. This will run the parity system .jar inside of a Docker Container to demonstrate the flexible deployment provided by Docker containers.
- Ubuntu 20.04 LTS (run locally or on VirtualBox 6.1.16 r140961)
- Linux x64 Compressed Archive for Java 1.8.0_271 (jdk-8u271-linux-x64.tar.gz)
- Docker Engine client and server version 19.03.13 for linux/amd64
- Mysql Ver 8.0.22 for Linux on x86_64 (MySQL Community Server - GPL)
- Postman v7.36.0 for Linux
-
Bootup Ubuntu and create Linux user "dockerubuntu"
-
Install Docker Engine according to the Docker Documentation
-
Install Linux Java version from the Oracle website.
-
Install MySQL server from APT repository and set user permissions according to the Getting Started Guide (Create user eml@localhost and table nist_cts_eml. Grant all permissions on eml@localhost to nist_cts_eml.)
-
Clone git repository from branch dev-docker. From the demo directory, move all folders and the json query unto the Desktop.
-
Open a command terminal in each of the 3 folder directories. In system-run, create a Docker image from the Dockerfile with this command:
docker build --tag system /home/dockerubuntu/Desktop/system-run/ -
Create a docker network to run the container in with this command:
docker network create --subnet=192.168.1.1/24 ctsnet -
Run the newly created Docker image inside a container using the specified IP with this command:
docker run --net ctsnet --ip 192.168.1.50 --name system1 system -
Now, using the terminal in the parity-run directory, run the jar file on the local IP with this command:
java -jar parity-client.jar 127.0.0.1 client0620.conf -
Run the cts-run shaded jar locally using this command:
java -jar eml-cts.jar 127.0.0.1 -
Run Postman and import the json file as a collection using the import button in the top left.
-
Run the imported collection of requests. If done correctly, you should see activity in the eml-cts.jar window, and a list of buy requests if you type "orders" in the running parity-client.jar console.
- Separate eml-cts into separate actors to deploy in separate docker contaners.
- Typing to an application that expects a console (prompt for output comes out, can't type to it (output only))
- Implement Docker Compose (Tool for defining and running multi-container Docker applications.)
- Run everything in a docker container including eml-cts components/actors.
- SQL connections and running eml-cts without requiring an SQL database.
- Setup Dockerfiles that copy application directories from Github and build Maven .jars inside the docker image.
Code Documentation
- Actor Pseudocode - LMA, LMM, TEUA
- RESTful Controller Payloads
- Position Manager
- Logging
- Time in CTS
- UML and Java Classes
- Simple Binary Encoding (SBE)
- SBE Quick Guide
- Auction Market
Building and Running the Project
- Setup Run and Drive - with YouTube videos
- Dependencies and Prerequisites
- Set Up MySQL
- Parity Terminal Client
- Project Build Steps
- In Case of Difficulty
Docker
- Docker Background
- Docker Setup Requirements
- Docker Setup Part 1
- Docker Setup Part 2
- Running EML-CTS as a Single Executable JAR
- Docker Quick Guide
General Tech Guides
Spring 2024 Updates