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

fix(docker-compose): fix volumes paths for rabbitmq #5

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

bcdady
Copy link

@bcdady bcdady commented Jul 24, 2023

Also makes docker_setup.sh compatible to run on MacOS (for development)

@bcdady
Copy link
Author

bcdady commented Jul 24, 2023

Addresses issue #4

@robertcoopercode
Copy link
Collaborator

Hi @bcdady, thanks for the PR! We will try to take a look at this, but it's not a priority right now. We were able to successfully setup a new self-hosted customer this week using the current docker-compose.yml file, so i'm not certain why you ran into issues with it. My intuition is that you might be using a newer version of the docker-compose CLI which uses slightly different syntax in the docker-compose.yml file. Our setup script downloads a pinned version of the docker-compose CLI (https://github.com/Basedash/self-hosted/blob/main/get-docker-compose.sh) that works with the current docker-compose.yml file.

Comment on lines +21 to +29
# accommodate different behavior by `sed` on MacOS
SPACER=""
if [[ "$OSTYPE" == "darwin"* ]]; then
SPACER="''"
fi

sed -i $SPACER "s/JWT_KEY=.*$/JWT_KEY=$JWTKEY/" docker.env
sed -i $SPACER "s/CRYPTO_KEY=.*$/CRYPTO_KEY=$CRYPTOKEY/" docker.env
sed -i $SPACER "s/POSTGRES_PASSWORD=.*$/POSTGRES_PASSWORD=$POSTGRESPASSWORD/" docker.env
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clever!

@bcdady
Copy link
Author

bcdady commented Jul 27, 2023

Our setup script downloads a pinned version of the docker-compose CLI (https://github.com/Basedash/self-hosted/blob/main/get-docker-compose.sh) that works with the current docker-compose.yml file.

That could be. Since I already have docker (podman) and docker-compose setup on my dev machine, I didn't need or want to redownload via the setup scripts.
I think it would be better to, instead of running docker compose on a virtual server, support running the containerized workload on a serverless framework, or on Kubernetes, such as via Helm chart.

@bcdady
Copy link
Author

bcdady commented Jul 27, 2023

Our setup script downloads a pinned version of the docker-compose CLI (https://github.com/Basedash/self-hosted/blob/main/get-docker-compose.sh) that works with the current docker-compose.yml file.

There are quite a few releases of docker-compose CLI available since the version specified in the script (1.29). Why is the setup script pinned to such a seemingly far backdated version/tag?

volumes:
- rabbitmq-data/:/var/lib/rabbitmq/
- rabbitmq-logs/:/var/log/rabbitmq
- rabbitmq-data:/var/lib/rabbitmq/
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the most essential part of the fix, to play nice with more recent versions of docker-compose.

@robertcoopercode
Copy link
Collaborator

Our setup script downloads a pinned version of the docker-compose CLI (https://github.com/Basedash/self-hosted/blob/main/get-docker-compose.sh) that works with the current docker-compose.yml file.

That could be. Since I already have docker (podman) and docker-compose setup on my dev machine, I didn't need or want to redownload via the setup scripts. I think it would be better to, instead of running docker compose on a virtual server, support running the containerized workload on a serverless framework, or on Kubernetes, such as via Helm chart.

We provide the docker-compose method as one way to run a self-hosted version of Basedash, but it is still possible to run it via Kubernetes and helm charts. For example, we were able to use AWS Cloudformation to spin up a self-hosted version of Basedash (see here for the cloudformation template).

@robertcoopercode
Copy link
Collaborator

here are quite a few releases of docker-compose CLI available since the version specified in the script (1.29). Why is the setup script pinned to such a seem

We simply haven't gotten around to upgrading to a newer version.

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

Successfully merging this pull request may close these issues.

2 participants