All Projects → metabrainz → artwork-redirect

metabrainz / artwork-redirect

Licence: MIT license
URL redirect service for the coverartarchive.org

Programming Languages

Less
1899 projects
python
139335 projects - #7 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to artwork-redirect

wayback
⏪ Tools to Work with the Various Internet Archive Wayback Machine APIs
Stars: ✭ 52 (+108%)
Mutual labels:  internet-archive
Openlibrary
One webpage for every book ever published!
Stars: ✭ 3,311 (+13144%)
Mutual labels:  internet-archive
WebCache
Chrome extension to view the cached version of the current webpage
Stars: ✭ 32 (+28%)
Mutual labels:  internet-archive
anchorage
Save your bookmark collection in the Internet Archive, or locally.
Stars: ✭ 19 (-24%)
Mutual labels:  internet-archive
MusaicFM
Screensaver inspired by Apple’s inbuilt iTunes Screensaver. It can display Artwork by Spotify or last.fm Profile Data.
Stars: ✭ 223 (+792%)
Mutual labels:  cover-art

Cover Art Archive URL redirect service

This service will redirect from coverartarchive.org URLs to archive.org URLs, taking into account MBID redirects caused by release merges.

For example, this URL:

https://coverartarchive.org/release/5b07fe49-39a9-47a6-97b3-e5005992fb2a/front.jpg

should redirect to:

https://archive.org/download/mbid-5b07fe49-39a9-47a6-97b3-e5005992fb2a/mbid-5b07fe49-39a9-47a6-97b3-e5005992fb2a-2270157148.jpg

Development setup

There are two ways of setting up the server: with and without Docker. First option might be easier if you are just getting started. Second requires having a MusicBrainz database set up on your machine.

Option 1: Docker-based

Make sure that you have Docker and Compose installed. To start the development server and its dependencies run:

$ docker-compose -f docker/docker-compose.dev.yml up --build

After all Docker images start you should be able to access the web server at localhost:8080.

Note: Keep in mind that any changes that you make won't show up until the server container is recreated. To do that you can simply stop the server (Ctrl + C) and run the command above again.

Option 2: Manual

CAA redirect server works with Python 3, so make sure that you have it installed. Create a virtual environment, if necessary.

Install all required packages using pip:

$ pip install -r requirements.txt

Copy config.default.ini to config.ini and adjust configuration values. You'd want to set up a connection to the instance of PostgreSQL with a MusicBrainz database that you should already have running.

Finally, run the artwork_redirect_server.py script to start the server.

All logging goes to stdout, including stacktraces, so its suitable for running inside of daemontools.

Testing

Currently some tests depend on an actual MusicBrainz database running in the background, so make sure to follow the setup process first. We use Pytest as a test runner. All tests can be run with the following command:

$ pytest

There are more ways to use Pytest (for example, to run only tests for a specific module). Check their documentation to see what kinds of additional options you have.

With Docker you can run all the tests like this:

$ docker-compose -f docker/docker-compose.test.yml up --build

You should see test results in the output.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].