Add support for local copy of artwork redirect#326
Add support for local copy of artwork redirect#326adhawkins wants to merge 7 commits intometabrainz:masterfrom
Conversation
d1a080d to
4cb29bc
Compare
|
Thanks again for submitting this! On Matrix I suggested renaming artwork-server.yml to artwork-redirect.yml for clarity. metabrainz/artwork-redirect#59 will also allow us to use existing environment variables in config.ini ( Other than that, I've already tested this locally and it works great. |
Good plan, I missed that when I was renaming everything. I've pushed a commit to do this (including updating the documentation). Do you mean the port that the docker container exposes to the host? Can this be an environment variable? I'll have a play. |
Yeah, the exposed port. An environment variable would be perfect. |
Ok, I've done this also. Think we're about done here now? |
These are used to access artwork externally (e.g., in a web browser), so should use the external host and port.
|
I realised I didn't have the redirect server specified to automatically restart. I've added a commit to achieve this. |
Adds support for running a local copy of the artwork redirect server.
Artwork redirect can be enabled using
./admin/configure add artwork-serverthen accessed using port 8081.Testing
$ ./admin/configure add artwork-redirect [...] $ docker compose up --build -d [...] $ curl 'http://localhost:8081/release/a6949d8e-c1eb-4eee-a670-680d28dd80e6' See: http://archive.org/download/mbid-a6949d8e-c1eb-4eee-a670-680d28dd80e6/index.jsonIf you have the CAA dump imported, you should also see images being linked to
localhost:8081from release pages.Note: I (mwiencek) use a local compose file which overrides the musicbrainz build context to never use prebuilt images.
$ cat local/build-musicbrainz.yml services: musicbrainz: build: context: build/musicbrainz $ cat .env MUSICBRAINZ_DOCKER_HOST_IPADDRCOL=127.0.0.1: NPM_CONFIG_REGISTRY=https://registry.yarnpkg.com COMPOSE_FILE=docker-compose.yml:compose/musicbrainz-standalone.yml:compose/publishing-db-port.yml:compose/artwork-redirect.yml:local/build-musicbrainz.yml