Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Damit der Spider endlich auch auf einer Hetzner-VM durchläuft #363

Merged
merged 3 commits into from
May 9, 2024

Conversation

marians
Copy link
Member

@marians marians commented May 9, 2024

Bisher brach der Spider immer ab, weil irgendwann die Job Queue leer war. Das lag letztlich wohl daran, dass der redis Service für die Welt zugänglich und schreibbar war.

Hier werden noch ein paar andere Dinge verbessert und Chromium aktualisiert.

@marians marians self-assigned this May 9, 2024

echo ""
echo "Set 'sysctl vm.overcommit_memory=1' to avoid OOM errors and allow background saving in redis"
$SSHCMD sysctl "vm.overcommit_memory=1"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ohne das loggt redis, dass es beim Persistieren von Daten zu Fehlern kommen kann.


echo ""
echo "Creating volume directories for redis"
$SSHCMD mkdir -p ./volumes/redis-data && chmod 777 ./volumes/redis-data
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sicher stellen, dass das Volume für den Redis Prozess schreibbar ist.

echo ""
echo "Allow writing to various paths in the redis container"
$SSHCMD docker compose exec redis chown -R redis:redis /var/spool/cron
$SSHCMD docker compose exec redis chown -R redis:redis /etc
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redis hat laut logs versucht, in diese Verzeichnisse zu schreiben, hatte aber keine Berechtigung.

echo "Pulling container images"
$SSHCMD docker compose pull --quiet redis manager
echo "Pulling redis container image"
$SSHCMD docker compose pull redis
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wir pullen erst mal nur das redis image. Das green spider image braucht lang, deshalb machen wir das später.

ports:
- "6379:6379"
- "127.0.0.1:6379:6379"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Das stellt sicher, dass der Port nur von der lokalen Maschine aus zugänglich ist.

@marians marians merged commit d12774c into main May 9, 2024
1 check passed
@marians marians deleted the fix-devops-script branch May 9, 2024 12:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant