Skip to content

Instantly share code, notes, and snippets.

@lavr
Created August 17, 2023 19:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lavr/1d0f1dc49836b437d111524535cf1fc2 to your computer and use it in GitHub Desktop.
Save lavr/1d0f1dc49836b437d111524535cf1fc2 to your computer and use it in GitHub Desktop.
Clean sentry queues
#!/bin/sh
#
# Clean sentry queues: kafka, zookeeper and redis
#
# To make backup: docker-compose run -v $(pwd)/sentry:/sentry-data/backup --rm -T -e SENTRY_LOG_LEVEL=CRITICAL web export > backup.json
for svc in zookeeper kafka redis clickhouse self-hosted_sentry-clickhouse-log self-hosted_sentry-kafka-log self-hosted_sentry-zookeeper-log; do
data_dir=`docker volume inspect sentry-$svc --format '{{ .Mountpoint }}'`
echo "Remove volume and data for sentry-$svc: $data_dir"
docker volume rm sentry-$svc
rm -rf $data_dir
done;
echo "Now run: ./install.sh"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment