Skip to content

Local development #1328

Answered by elrido
SamoKopecky asked this question in Q&A
May 11, 2024 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

Indeed, for my local IDE-based development I too use our own container images.

To run the locally checked out repo I use the following helper script:

#!/bin/sh
docker run -d --rm --name pb -p 127.0.0.1:8080:8080 -u $(id -u) -v ~/[your/git/repo/path/here]:/var/www:rw privatebin/unit-alpine
echo "Container:  docker stop pb"
echo "Website:    http://127.0.0.1:8080/"

When changing JS files, you will need to update the SRI hashes (or temporarily remove them from the template used), for example by running phpunit and then docker restart pb to ensure the webserver- and php-op-caches get refreshed and reloading the page in the browser actually loads the new code and the container doesn't serve yo…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@elrido
Comment options

Answer selected by rugk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
3 participants