A thing to fix broken jpegs
https://en.wikipedia.org/wiki/Brigitte_Bardot
Who was an animal rights activist, there are also a fair few jpegs of here out there in the wild. She was also riotously French, of course
Ensure you have Rust installed.
cd jpeg-repair-server
cargo runThe server will be available at http://localhost:3000. By default, it looks for photos in ../margot-photos. You can override this with the BARDOT_PHOTOS_DIR environment variable.
docker build -t bardot .
docker run -p 3000:3000 -v $(pwd)/margot-photos:/photos bardotcd jpeg-repair-server
cargo testTo deploy to a VPS running Docker without a private registry, you can use docker save and docker load.
-
Build and save the image locally:
docker build -t bardot . docker save bardot | gzip > bardot.tar.gz
-
Copy the image to your VPS:
scp bardot.tar.gz user@your-vps-ip:/home/user/
-
Load and run on the VPS:
ssh user@your-vps-ip "docker load < /home/user/bardot.tar.gz" ssh user@your-vps-ip "docker run -d --name bardot -p 3000:3000 -v /path/to/your/photos:/photos --restart unless-stopped bardot"