Build all-in-one image from source


I’m relatively new to the docker ecosystem.
I would like to build Baserow into a single docker image from source.

In the source root folder I can see the docker-compose.yml files, but the docker-compose.all-in-one.yml only makes docker-compose to download the already built image from the net, if I understand it correctly.

How can I build the all-in-one image from source?

Thank you for the help in advance!

There is likely a documentation page I missed, so I would appreciate if someone could point me in the right direction, at least about what tool or file should I search for.

Hello @valaki, have you seen this guide: Install with Docker compose // Baserow?

Thank you Olga for your reply!

Unfortunately in the documentation (including the guide you linked) I could only find information about using the ready-for-use image from, but not how to build the image for myself.

Today I did another try solving this myself, and now I suspect I should use the files in /deploy/all-in-one

However, after creating following .env file in /deploy/all-in-one:

.env file content

and running sudo docker-compose build (still in /deploy/all-in-one), I get the following error at the start of the building process:

Error message
user@user:/mnt/hgfs/!%home!%user!%osztott/baserow-1.22.2/deploy/all-in-one$ sudo docker-compose build
mailhog uses an image, skipping
Building baserow_all_in_one
[+] Building 0.5s (5/5) FINISHED                                                                                                                         docker:default
=> [internal] load build definition from Dockerfile                                                                                                               0.0s
=> => transferring dockerfile: 4.86kB                                                                                                                             0.0s
=> [internal] load .dockerignore                                                                                                                                  0.0s
=> => transferring context: 173B                                                                                                                                  0.0s
=> CANCELED [internal] load metadata for                                                                                   0.5s
=> CANCELED [internal] load metadata for                                                                                 0.5s
=> ERROR [internal] load metadata for                                                                               0.5s
> [internal] load metadata for
  5 |     FROM $FROM_BACKEND_IMAGE as backend_image_base
  6 |     # hadolint ignore=DL3006
  7 | >>> FROM $FROM_WEBFRONTEND_IMAGE as web_frontend_image_base
  8 |     FROM debian:bullseye-slim as base
  9 |
ERROR: failed to solve: baserow_web-frontend: pull access denied, repository does not exist or may require authorization: server message: insufficient_scope: authorization failed
ERROR: Service 'baserow_all_in_one' failed to build : Build failed
Error message in screenshot

Got it, then I’ll ask someone from the dev team to jump in :slightly_smiling_face:

1 Like

Hi @valaki, the commands below should do the trick. You would need to check out the repository, and build the backend and web-frontend images first because it’s a multistage Docker build.

git clone
cd baserow
docker build . -t -f backend/Dockerfile
docker build . -t -f web-frontend/Dockerfile
docker build . -t local_all_in_one -f deploy/all-in-one/Dockerfile
docker run local_all_in_one
1 Like