Standalone docker container
If your project has its docker-compose setup, you can add Diffy's container to the mix to take screenshots from your local environment. The following few steps will allow you to do this.
Clone worker code
Clone the code from https://github.com/DiffyWebsite/diffy-worker to some directory in your project where it makes sense.
Set up .env file
In the worker directory, copy .env.example
to .env
and edit DIFFY_API_KEY
and DIFFY_PROJECT_ID
variables.
The key can be generated in the app, and you need to grab project ID from the URL of your project.
Add container
Add to your docker-compose.yml
Now remember to restart your container setup so the Diffy container is pulled in.
Take screenshots from the container
Now you can SSH to Diffy container (docker exec -it diffy bash
) and then in the worker code you can run screenshots:
URL is the name of the container you linked in your docker-compose file
Last updated