Skip to content

Docker profiles for developing with local code#649

Open
bwbohl wants to merge 63 commits into
Edirom:developfrom
baz-ga:ftr/local-development
Open

Docker profiles for developing with local code#649
bwbohl wants to merge 63 commits into
Edirom:developfrom
baz-ga:ftr/local-development

Conversation

@bwbohl
Copy link
Copy Markdown
Member

@bwbohl bwbohl commented Mar 4, 2026

Description, Context and related Issue

The docker-compose setup has positively impacted Edirom Online development, and especially when doing code reviews. The downside is however, that the code sued when building backend and forntend would have to be available online. This pull request adds the ability to build with local code clones and moreover to bind mount the local code to a shared builder architecture that allows interactive development.

Refs # dang ;-)

How Has This Been Tested?

Locally

Types of changes

  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation Update
  • Improvement

Overview

  • I have updated the inline documentation accordingly.
  • I have performed a self-review of my code, according to the style guide
  • I have read the CONTRIBUTING document.

@github-project-automation github-project-automation Bot moved this to In Progress in Edirom Development Mar 4, 2026
@bwbohl bwbohl requested a review from daniel-jettka March 4, 2026 14:33
@bwbohl bwbohl marked this pull request as ready for review March 9, 2026 15:18
@bwbohl bwbohl added this to the 2.3.0 milestone Mar 9, 2026
@bwbohl bwbohl moved this from In Progress to Ready for Review in Edirom Development Mar 9, 2026
@bwbohl bwbohl requested review from peterstadler March 11, 2026 20:25
@hizclick hizclick self-requested a review March 16, 2026 09:55
@hizclick
Copy link
Copy Markdown
Contributor

hizclick commented Mar 17, 2026

The local-frontend workflow invokes ./build.sh, but the frontend repository no longer has the script. ref: (https://github.com/Edirom/Edirom-Online-Frontend/pull/105)

> [local-edirom-online-frontend eo-builder 4/4] RUN if [ -n "8080" ] && [ "8080" != "8080" ]; then         echo "Writing backend.port=8080 to local.properties…";         if [ -f "./local.properties" ]; then             sed -i '/^backend\.port=/d' local.properties;             echo "backend.port=8080" >> local.properties;         else             echo "backend.port=8080" >> local.properties;         fi     fi &&     echo "Building Frontend XAR..." &&     ./build.sh:
0.190 Building Frontend XAR...
0.190 /bin/sh: 1: ./build.sh: not found

@bwbohl
Copy link
Copy Markdown
Member Author

bwbohl commented Mar 17, 2026

The local-frontend workflow invokes ./build.sh, but the frontend repository no longer has the script. ref: (https://github.com/Edirom/Edirom-Online-Frontend/pull/105)

> [local-edirom-online-frontend eo-builder 4/4] RUN if [ -n "8080" ] && [ "8080" != "8080" ]; then         echo "Writing backend.port=8080 to local.properties…";         if [ -f "./local.properties" ]; then             sed -i '/^backend\.port=/d' local.properties;             echo "backend.port=8080" >> local.properties;         else             echo "backend.port=8080" >> local.properties;         fi     fi &&     echo "Building Frontend XAR..." &&     ./build.sh:
0.190 Building Frontend XAR...
0.190 /bin/sh: 1: ./build.sh: not found

thanks for reminding me, will fix ;-)

@bwbohl bwbohl force-pushed the ftr/local-development branch from 6583a8d to ae879ec Compare March 24, 2026 16:11
@bwbohl
Copy link
Copy Markdown
Member Author

bwbohl commented Mar 24, 2026

I uodated the command and rebased the branch, this is ready for review

@daniel-jettka
Copy link
Copy Markdown
Contributor

Following the build steps in https://github.com/baz-ga/Edirom-Online/tree/ftr/local-development I get the following:

image

Comment thread docs/advanced-developer-options.md
@hizclick
Copy link
Copy Markdown
Contributor

./build.sh references the deprecated ./build.sh
Replacing it with

sencha app build production

fixed the issue for me

@bwbohl
Copy link
Copy Markdown
Member Author

bwbohl commented Mar 25, 2026

./build.sh references the deprecated ./build.sh Replacing it with

sencha app build production

fixed the issue for me

Many thanks for spotting, I forgot to align both Dockerfiles… just fixed it ;-)

@bwbohl
Copy link
Copy Markdown
Member Author

bwbohl commented Mar 25, 2026

Following the build steps in https://github.com/baz-ga/Edirom-Online/tree/ftr/local-development I get the following:

image

You mean for building the regular services?
Did it build successfully or not?

@daniel-jettka
Copy link
Copy Markdown
Contributor

daniel-jettka commented Mar 25, 2026

Following the build steps in https://github.com/baz-ga/Edirom-Online/tree/ftr/local-development I get the following:
image

You mean for building the regular services? Did it build successfully or not?

Sorry, I could have been clearer... Build failed with this message.

@daniel-jettka
Copy link
Copy Markdown
Contributor

The problem probably is that at several places in the docs it says docker compose build builder while it has to be docker compose build edirom-online-builder, right?

@bwbohl
Copy link
Copy Markdown
Member Author

bwbohl commented Mar 25, 2026

I was just getting to that…

@daniel-jettka
Copy link
Copy Markdown
Contributor

docker compose build edirom-online-builder works only if I set FE_LOCAL_SOURCE and BE_LOCAL_SOURCE

When I do docker compose --profile default up afterwards I get... duplicate containers?!

image

@bwbohl
Copy link
Copy Markdown
Member Author

bwbohl commented Mar 25, 2026

It seems I only tested with all the variables set, and the root cause was a bake bleed-through of the profiles: apparently, a child service’s profiles: definition doesn’t override but extend those of the parent service. Thus, the local services were always built on launching the default profile.

Moreover, the README wasn’t up to date – at some point, I decided to rename the services for consistency and fixed that, too. Please retest following the README. If it fails again, we’ll push the pull request to the next release.

Many thanks for your testing efforts!!

@all-contributors, please add @daniel-jettka and @hizclick for testing

@daniel-jettka
Copy link
Copy Markdown
Contributor

Thanks @bwbohl I am really sorry... I tried the building again with a fresh clone, Docker all cleaned up and all env variables unset, but get a notification invalid mount config for type "bind": field Source must not be empty which stops the docker compose actions. I even get this on calling docker compose config. Not sure, maybe I am doing sth wrong, but I am afraid we hace to focus on finishing the release now.

Let's forward the feature to our next release. I am looking forward to having it because it'll great to be able to build from local sources.

@daniel-jettka daniel-jettka modified the milestones: 2.3.0, 2.4.0 Mar 26, 2026
bwbohl added 28 commits May 4, 2026 15:33
The dependency is there but depends_on only controls runtime startup
The sections were unmaintained, and made the file too long, maybe something for a separate file, later
* fix build command
* add ARG SENCHA_BUILD_ENV
… services

Docker Compose v5 bake inherits `profiles:` from parent services via `extends:`, the child’s definition doesn’t seem to be an explicit override. Removing `extends:` from the two local services fixed it.
@bwbohl bwbohl force-pushed the ftr/local-development branch from 28ca487 to a47d5e1 Compare May 4, 2026 13:46
@krHERO krHERO requested a review from feuerbart May 6, 2026 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Ready for Review

Development

Successfully merging this pull request may close these issues.

3 participants