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

Invalid interpolation format for x-shared-env.COMPOSE_PROFILES #12081

Open
5 tasks done
hanktrizz opened this issue Dec 25, 2024 · 3 comments · May be fixed by #12093
Open
5 tasks done

Invalid interpolation format for x-shared-env.COMPOSE_PROFILES #12081

hanktrizz opened this issue Dec 25, 2024 · 3 comments · May be fixed by #12093
Labels
good first issue Good first issue for newcomers

Comments

@hanktrizz
Copy link

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

0.14.2

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Clone the latest source from https://github.com/langgenius/dify.git and follow the docker steps as outlined in the documentation page: https://docs.dify.ai/getting-started/install-self-hosted/docker-compose#starting-dify

✔️ Expected Behavior

Expected output of the containers, layers, images to be pulled smoothly and exiting successfully.

❌ Actual Behavior

image

Instead, the interpolated environment variable, in particular, the COMPOSE_PROFILES is causing a problem due to a missing extra $ such that the correct version of the line should like this:
COMPOSE_PROFILES=$${VECTOR_STORE:-weaviate}

Copy link

dosubot bot commented Dec 25, 2024

Hey @hanktrizz! 👋 I'm here to help you with bug fixing, answering questions, and becoming a contributor. If you need assistance, feel free to ask.

The issue you're encountering with the "Invalid interpolation format" error in Docker Compose is likely due to incorrect syntax for environment variable interpolation. In Docker Compose files, the correct syntax for environment variable interpolation is ${VARIABLE_NAME:-default_value}. This allows you to specify a default value if the environment variable is not set.

For the COMPOSE_PROFILES variable, you should use the following format:

COMPOSE_PROFILES: ${VECTOR_STORE:-weaviate}

This syntax ensures that if VECTOR_STORE is not set, weaviate will be used as the default value. Make sure your Docker Compose file uses this format to avoid interpolation errors [1].

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@crazywoola crazywoola added the good first issue Good first issue for newcomers label Dec 25, 2024
@hanktrizz
Copy link
Author

@crazywoola would it be ok for me to fix this via a simple PR? Thanks.

@hanktrizz
Copy link
Author

Either way I have raised a PR for this issue here https://github.com/langgenius/dify/pull/12093

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good first issue for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants