Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PR43 follow-up: replace the problematic nested volume mounts with bind mounts and add shared init volume container #55

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jonasbardino
Copy link
Contributor

This is as proposed in relation to PR43 and the fallout it caused regarding build errors and races in launch from pristine clone e.g. when running in the existing CI.

Introduces the shared volume pre-init container to eliminate start-up races.

Uses env variables to allow flexible vgrid_files_readonly and mig_system_run locations, in order to hopefully address the needs originally motivating PR43.

… a shared

volume init container. This is as proposed in relation to PR43 and the fallout
it caused regarding build errors and races in launch from pristine clone e.g.
when running in the existing CI.

Introduces the shared volume pre-init container to eliminate start-up races.

Uses env variables to allow flexible vgrid_files_readonly and mig_system_run
locations, in order to hopefully address the needs originally motivating PR43.
@jonasbardino jonasbardino added bug Something isn't working enhancement New feature or request labels Apr 17, 2024
@jonasbardino jonasbardino added this to the Rocky9 Deployments milestone Apr 17, 2024
@Bjarke42
Copy link

Bjarke42 commented Apr 29, 2024

@jonasbardino I have not tried to implement this into my system, but it get an error.

ERROR: for migrid  Cannot create container for service migrid: invalid mount config for type "bind": field Source must not be empty

ERROR: for migrid  Cannot create container for service migrid: invalid mount config for type "bind": field Source must not be empty
ERROR: Encountered errors while bringing up the project.

my volumes for migrid is the following in docker-compose.override.yml

migrid:
    volumes:
      - ../au-overlay/erda-test2/skin/erda-ucph-science:/home/mig/mig/images/skin/erda-ucph-science:ro
      - ../au-overlay/erda-test2/skin/icons:/home/mig/mig/images/icons:ro
      - type: volume
        source: state
        target: /home/mig/state
      - type: bind
        source: /mnt/erda-x/erda-test2/vgrid_files_writable
        target: /home/mig/state/vgrid_files_readonly
        read_only: true
      - type: bind
        source: /mnt/erda-x/erda-test2/mig_system_run
        target: /home/mig/state/mig_system_run

@jonasbardino
Copy link
Contributor Author

Can you please verify that you don't end up with a source that has empty value as the error message seems to indicate?
One plausible cause could be an empty env value used es source. E.g. in the new

      - type: bind
        source: ${VGRID_FILES_WRITABLE}

@jonasbardino
Copy link
Contributor Author

You can find good hints about suitable values for the three new bind source-related variables in production.env from line 158 to 180.

@Bjarke42
Copy link

When you introduce variables into docker-compose, then i cannot override them, so it does not make any sense to have docker-compose.override, but that leaves me with alot of problems with the other stuff already in my docker-compose.override.

@jonasbardino
Copy link
Contributor Author

I'm not sure I understand why you'd want to have docker-compose overrides for values that you can already configure in env. Doesn't it give you the necessary flexibility to 'just' specify your custom locations there?

@Bjarke42
Copy link

This is my current docker-compose.override
I also have links for settingup skins and icons in migrid.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants