Skip to content

Commit 1b623b0

Browse files
author
Carole Corley
authored
Merge pull request #82 from LinuxForHealth/add-linuxone
Added LinuxONE instructions
2 parents 2bf63cf + 4d65125 commit 1b623b0

31 files changed

Lines changed: 678 additions & 5 deletions
1.35 KB
Binary file not shown.

‎docs/.doctrees/environment.pickle‎

4.95 KB
Binary file not shown.

‎docs/.doctrees/index.doctree‎

271 Bytes
Binary file not shown.
19.3 KB
Binary file not shown.

‎docs/_images/CreateLinuxONEVM.png‎

268 KB
Loading

‎docs/_sources/devices/raspberrypi.rst.txt‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,3 +133,6 @@ Start connect::
133133

134134
pipenv run connect
135135

136+
Send a Message to LinuxForHealth
137+
================================
138+
Follow the `Quickstart steps <tutorials/quickstart.html#send-a-message-to-linuxforhealth>`_ to send a message to LinuxForHealth. Be sure to use the IP of your device in the OpenAPI /docs URL.

‎docs/_sources/index.rst.txt‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,12 @@ This diagram shows the power of the LFH network where a transaction is submitted
140140
deployment/container.rst
141141
deployment/kubernetes.rst
142142

143+
.. toctree::
144+
:maxdepth: 3
145+
:caption: Devices:
146+
147+
platforms/linuxone.rst
148+
143149
.. toctree::
144150
:maxdepth: 3
145151
:caption: Devices:
Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
LinuxONE
2+
********
3+
4+
Overview
5+
========
6+
LinuxForHealth is deployable to amd64, s390x and arm64 (aarch64) platforms and may be built to support other chip architectures. These instructions explain how to bring up a LinuxONE VM from scratch and were tested with a VM from the IBM LinuxONE OSS Community Cloud. All steps are executed on the LinuxONE VM, with the exception of the initial steps to deploy the VM.
7+
8+
Prerequisites
9+
=============
10+
- An ssh utility such as OpenSSH must be installed on the computer you will use to connect to your LinuxONE VM.
11+
12+
Deploy a LinuxONE VM
13+
====================
14+
These instructions explain how to deploy a new LinuxONE VM in the IBM LinuxONE OSS Community Cloud. If you already have a LinuxONE VM running Ubuntu 20.04, skip to the next section. If you do not have an account in the IBM LinuxONE OSS Community Cloud, you can start with `Getting started with LinuxONE <https://developer.ibm.com/gettingstarted/ibm-linuxone>`_, where you can sign up for a free trial.
15+
16+
1. Create an ssh key pair to use to ssh into the VM you will create. Provide a file name when requested. In this case, we used ``lfhcommvm1`` with no path, which creates the key pair in the current directory::
17+
18+
cd ~/.ssh
19+
ssh-keygen -t rsa
20+
21+
2. Log into the `IBM LinuxONE OSS Community Cloud <https://linuxone.cloud.marist.edu/oss/#/login>`_ and click "Manage Instances" in the "Service Catalog".
22+
23+
3. Click "Create" and populate the fields. Choose "General Purpose VM", provide a name for the VM, select the Ubuntu 20.04 image, select the LinuxONE flavor, and elect to import the public key (.pub) that you created in a previous step.
24+
25+
.. image:: /images/CreateLinuxONEVM.png
26+
:width: 600
27+
28+
4. Click "Create" and wait a few minutes for your VM to start. Once started, note the IP address of your new VM.
29+
30+
5. Configure your computer to ssh into your new VM. For example, you can add this section to your OpenSSH .ssh/config file::
31+
32+
Host lfh-comm-vm1
33+
HostName <your VM's IP>
34+
User linux1
35+
IdentityFile ~/.ssh/lfhcommvm1
36+
37+
6. ssh into your LinuxONE VM::
38+
39+
ssh lfh-comm-vm1
40+
41+
Configure the Python Environment
42+
================================
43+
On your LinuxONE VM, run the following commands to install python, pip and pipenv::
44+
45+
sudo apt-get update
46+
sudo apt install python3-pip
47+
pip install --upgrade pip
48+
pip3 install pipenv
49+
50+
Add ``PATH=/home/linux1/.local/bin:$PATH`` to your ~/.bashrc file and run::
51+
52+
source .bashrc
53+
54+
Install Docker and docker-compose
55+
=================================
56+
Install docker and docker-compose via the following steps::
57+
58+
sudo snap install docker
59+
sudo groupadd docker
60+
sudo usermod -aG docker $USER
61+
sudo snap start docker
62+
63+
Reboot for the user group changes to take effect::
64+
65+
sudo reboot
66+
67+
Build and Install librdkafka
68+
=================================
69+
Build and install librdkafka. Note that this step is necessary to make the correct version of librdkafka available on this platform::
70+
71+
git clone https://github.com/edenhill/librdkafka.git
72+
cd librdkafka
73+
./configure
74+
make
75+
sudo make install
76+
sudo ldconfig
77+
cd ..
78+
79+
Configure and Run LinuxForHealth connect
80+
========================================
81+
Clone and configure LinuxForHealth connect::
82+
83+
git clone https://github.com/LinuxForHealth/connect.git
84+
cd connect
85+
cp platforms/s390x/Dockerfile .
86+
cp platforms/s390x/docker-compose.yml .
87+
88+
Create a virtual environment::
89+
90+
pipenv sync --dev
91+
92+
Bring up the LinuxForHealth services::
93+
94+
docker-compose up -d nats-server ipfs-node-0 zookeeper kafka ipfs-cluster-0
95+
96+
Start connect::
97+
98+
pipenv run connect
99+
100+
101+
Send a Message to LinuxForHealth
102+
================================
103+
Follow the `Quickstart steps </tutorials/quickstart.html#send-a-message-to-linuxforhealth>`_ to send a message to LinuxForHealth. Be sure to use the IP of your VM in the OpenAPI /docs URL.

‎docs/application-configuration.html‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,10 @@
118118
</ul>
119119
<p class="caption"><span class="caption-text">Devices:</span></p>
120120
<ul>
121+
<li class="toctree-l1"><a class="reference internal" href="platforms/linuxone.html">LinuxONE</a></li>
122+
</ul>
123+
<p class="caption"><span class="caption-text">Devices:</span></p>
124+
<ul>
121125
<li class="toctree-l1"><a class="reference internal" href="devices/raspberrypi.html">Raspberry Pi</a></li>
122126
</ul>
123127

‎docs/deployment/compose.html‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,10 @@
117117
</ul>
118118
<p class="caption"><span class="caption-text">Devices:</span></p>
119119
<ul>
120+
<li class="toctree-l1"><a class="reference internal" href="../platforms/linuxone.html">LinuxONE</a></li>
121+
</ul>
122+
<p class="caption"><span class="caption-text">Devices:</span></p>
123+
<ul>
120124
<li class="toctree-l1"><a class="reference internal" href="../devices/raspberrypi.html">Raspberry Pi</a></li>
121125
</ul>
122126

0 commit comments

Comments
 (0)