Table of Contents
Table of Contents | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
...
Code Block |
---|
systemctl --no-pager status user.slice > /dev/null 2>&1 && echo 'OK: Systemd is running' || echo 'FAIL: Systemd not running' |
...
Install docker for your distribution
Ensure WSL is up-to-date
Code Block wsl --update
Install prerequisites for Docker
Code Block sudo apt update && sudo apt upgrade sudo apt install --no-install-recommends apt-transport-https ca-certificates curl gnupg2
Still in the terminal, change the network config so that Docker can interact with the firewall using the command below:
Code Block sudo update-alternatives --config iptables
When asked, choose iptables-legacy.
Install Docker
Make sure Ubuntu trusts the Docker packagesCode Block . /etc/os-release curl -fsSL https://download.docker.com/linux/${ID}/gpg | sudo tee /etc/apt/trusted.gpg.d/docker.asc echo "deb [arch=amd64] https://download.docker.com/linux/${ID} ${VERSION_CODENAME} stable" | sudo tee /etc/apt/sources.list.d/docker.list sudo apt update
Then install Docker, Docker-Compose CLI, and
containerd
:Code Block sudo apt install docker-ce docker-ce-cli containerd.io
Verify the Docker service status
Code Block sudo systemctl status docker
Configure a user to work with Docker (Optional, it will allow to run
docker
command without root access)
Add our user to the Docker group:Code Block sudo usermod -aG docker $USER
To confirm the change worked, close the terminal tab and open a new Ubuntu tab, then run:
Code Block groups
It should now list the docker group if it doesn't, repeat the previous command.
Now, we'll need to assign a group ID to Docker. First, let's check if an example ID is unused:
Code Block getent group | grep 36257 || echo "This ID is not in use."
If not, retry with another ID. After finding an unused ID, use it in the following step:
Code Block sudo sed -i -e 's/^\(docker:x\):[^:]\+/\1:36257/' /etc/group
We'll need to restart Ubuntu now. To do this, close the terminal, then open the command line as administrator and run:
Code Block wsl --shutdown
Wait 7-10 seconds to open the Linux terminal and run the following commands:
Code Block sudo systemctl status docker docker ps -a
Install python v3
Python provides an ability to manipulate with deployment locally, and part of scripts using it to update the version of containers, discovery information, etc. It can be installed from Python.org
check the Python version
Code Block |
---|
python --version |
It should be Python 3.10.12
or higher
Install JQ
jq is a tool to manipulate with JSON objects
Code Block |
---|
sudo apt-get install jq |
Check jq version, it should be like jq-1.6
Code Block |
---|
jq --version |
Expose Docker to Windows shell and Idea
To expose the Docker command a simple executable file can be added to Windows $PATH
:
Code Block | ||
---|---|---|
| ||
@echo off
wsl -e docker %* |
To expose Docker's TCP port securely, you can use an SSH tunnel from Windows to WSL.
Install SSH Server in WSL:
Update your packages and install OpenSSH:
Code Block sudo apt update sudo apt install openssh-server
Ensure SSH is running:
Code Block sudo service ssh start
Configure SSH (if necessary):
You might want to configure SSH to start automatically or adjust settings, but default settings are usually sufficient for local development.
Create an SSH Tunnel from Windows:
Open a command prompt or PowerShell in Windows.
Create an SSH tunnel mapping the Docker socket:
Code Block ssh -L localhost:2375:/var/run/docker.sock your_wsl_username@localhost
This command forwards the local port
2375
to the Docker socket in WSL. Replaceyour_wsl_username
with your actual WSL username.
Set
DOCKER_HOST
in Windows:Set the
DOCKER_HOST
environment variable to use the local forwarded port (in PowerShell or using Edit the System environment variables in Control Panel):
Code Block DOCKER_HOST = "tcp://localhost:2375"
Linux
Will be added
MacOS
Will be added
...
Enabling container management
A suggested solution is to use the Portainer (under Zip License).
...
Code Block |
---|
docker run -d -p 900018000:90008000 -p 9443:9443 --name portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:latest |
It became available in the browser via
Code Block |
---|
http://localhost:9000
# or
https://localhost:9443 |
Docker compose profiles
...
mgr-tenants is responsible for managing tenants in the system
mgr-applications is responsible for applications and module discovery
mgr-tenant-entitlements is responsible for managing applications per tenant (entitlement, upgrade and revoke processes per tenant)
app-platform-minimal
This deployment contains a set of required modules to operate with Folio platform`app-platform-minimal` contains basic functionality for Eureka platform:
User and AuthUsers management (
mod-users-keycloak
+mod-users
+mod-users-bl
)Authentication and authorization (
keycloak
+mod-login-keycloak
+ sidecars)Capability/Role/Policy management (
mod-roles-keycloak
)Scheduled timers support (
mod-scheduler
)Notes (
mod-notes
)Tenant settings management (
mod-settings
)
Installation
app-platform-minimal
installation instruction is described in eureka-platform-bootstrap README.md in section Run applications in docker