Commit b8e17a8b authored by Creak's avatar Creak
Browse files

Add clean script

parent cf3830d6
Pipeline #19067 passed with stage
in 8 seconds
......@@ -5,4 +5,4 @@ linter:
stage: test
image: koalaman/shellcheck-alpine
script:
- shellcheck setup.sh
- shellcheck setup.sh clean.sh
......@@ -8,6 +8,8 @@ This repo is here to help installing Funkwhale using Docker. It follows the
Prerequisites:
* docker-compose
## Setup
To set up your instance, clone this repo and enter the directory, then run the
script `./setup.sh`.
......@@ -18,9 +20,22 @@ pass them to it directly. See the help with this command:
./setup --help
```
## Clean
If you are doing tests, you might want to start from a blank slate each time.
The `clean.sh` script cleans the Docker containers, their volumes and the
residual files. Since running the containers needs to create volume bindings,
this script needs sudo rights in order to clean the files created with root
access.
Because of the security risk, please take a look at the script to understand
what it does: [`clean.sh`](./clean.sh)
## Developer
Prerequisites:
* spellchecker
[docs-multi-container]: https://docs.funkwhale.audio/installation/docker.html#docker-multi-container
#!/bin/bash
set -e
if [ -d funkwhale ]; then
pushd funkwhale
docker-compose down
docker volume prune -f
if [ -d data ]; then
sudo rm -rf data
fi
popd
rm -rf funkwhale
fi
if [ -d /srv/funkwhale ]; then
sudo rm -rf /srv/funkwhale
fi
rm -rf templates
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment