1. Setting up first service as container
Setting up Apache web server using Docker, and pulling an image from our GitLab registry, with Let's Encrypt SSL.
Notes#
This guide is 100% NOT required, you will do similar steps in the next guide. Leaving it be until we give it a final verdict.
Create a NEW, CLEAN Rocky Linux virtual machine on cPouta for V1! Otherwise there might be conflicts!
In this quide we will setup simple apache server by applying Docker container technology
Introduction#
Introduction here
Prerequisites#
- Rocky Linux 10 running on a CSC cPouta virtual machine
- Ports 80 and 443 open
Docker setup#
-
Initial updates and installs
Wait a moment and ssh back in.
Save your fip-aaa-bbb-ccc-ddd.kaj.poutavm.fi address somewhere. -
Add Docker repository and install Docker
# Add Docker repo sudo dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo # Install Docker and Compose plugin sudo dnf install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin -y # Start Docker sudo systemctl enable --now docker # Test Docker sudo docker run hello-world -
Docker network and directories
-
Create a Docker compose file
We are going to use our favourite apache server container which is livin on gitlab repository: https://gitlab.labranet.jamk.fi/ref-product-line-v1-2025/apache-test
You should also be able to see latest docker container at : https://gitlab.labranet.jamk.fi/ref-product-line-v1-2025/apache-test/container_registry/926
```bash
mkdir apache-service
cd apache-service
sudo vi docker-compose.yml
```
- Start Containers
After this, you should have a Let’s Encrypt certified PrestaShop running at
fip-aaa-bbb-ccc-ddd.kaj.poutavm.fi.
Extra notes#
- Ensure MySQL is ready before PrestaShop starts; consider retrying connections if needed.
- Check folder permissions for
./ssland./html. - Verify DNS points correctly to the server for SSL to work.
- If Docker reports irrelevant sections, check YAML indentation and Compose version.