ddev / ddev-opensearch

OpenSearch add-on for DDEV
Apache License 2.0
7 stars 1 forks source link

Cannot change version #3

Closed PatrickWhitehouse closed 2 months ago

PatrickWhitehouse commented 6 months ago

I'm trying to use 2.12.0 and I have set this inside .ddev/opensearch/Dockerfilebut when checking the version by visiting the url echoed in ddev describe, I'm consistently seeing 2.13.0.

rfay commented 6 months ago

or

~/.ddev/bin/docker-compose -f .ddev/.ddev-docker-compose-full.yaml build --no-cache --progress=plain
cmuench commented 5 months ago

Related to #4

cmuench commented 5 months ago

@PatrickWhitehouse Did the tip of @rfay help you?

PatrickWhitehouse commented 5 months ago

@PatrickWhitehouse Did the tip of @rfay help you?

@cmuench - Nope. I have just tried the suggested fix above, and i'm still seeing 2.13.0 despite having 2.12.0 set.

cmuench commented 5 months ago

@PatrickWhitehouse Did the tip of @rfay help you?

@cmuench - Nope. I have just tried the suggested fix above, and i'm still seeing 2.13.0 despite having 2.12.0 set.

ok. I will try it on my machine.

cmuench commented 5 months ago

@PatrickWhitehouse I was able to run 2.12.0 on my machine. I just pushed my example project to Github as reference. https://github.com/cmuench/ddev-opensearch-2.12.0-example

stasadev commented 5 months ago

@PatrickWhitehouse,

You need to delete the existing opensearch volume before the downgrade:

ddev stop

docker volume ls | grep opensearch # to see the volume name

docker volume rm ddev-<projectname>_opensearch
PatrickWhitehouse commented 5 months ago

@stasadev - After the above, is it just a case of restarting via ddev restart? And to confirm, I can see the version by following the url given in ddev describe ?

stasadev commented 5 months ago

After the above, is it just a case of restarting via ddev restart?

As you can see, I added ddev stop before deleting the volume, so it doesn't matter if you run ddev start or ddev restart afterwards, each will do its job.

And to confirm, I can see the version by following the url given in ddev describe ?

Yes, when you change the version in .ddev/opensearch/Dockerfile and docker-compose.opensearch.yaml and remove #ddev-generated from these files, and have the old opensearch volume removed, it should work.

PatrickWhitehouse commented 5 months ago

Really strange because I'm able to swap the version of the dashboard fine. 2.12.0 seems to show 2.13.0 if I curl the url for the ouput.

stasadev commented 5 months ago

Try this with a new test project:

mkdir test-opensearch && cd test-opensearch
ddev config --auto
ddev get ddev/ddev-opensearch

Modify .ddev/opensearch/Dockerfile and .ddev/docker-compose.opensearch.yaml and run ddev start.

cmuench commented 4 months ago

@PatrickWhitehouse Did the recommendation of @stasadev work for you?

cmuench commented 2 months ago

I close this issue due to inactivity.

rdeelstra commented 1 month ago

Faced the same issue, while other versions did work ok, the 2.12.0 was somehow linked to the latest version through the docker cache it seems. Eventually I had to do this to make it work @PatrickWhitehouse: docker system prune -a