Troubleshooting¶
This page covers common troubleshooting steps for Canasta installations.
Contents¶
- Checking container status
- Viewing container logs
- Log file locations
- Enabling the MediaWiki debug log
- Accessing the database
- Running commands inside containers
- Common issues
Checking container status¶
To see if your Canasta containers are running:
Viewing container logs¶
To view logs from the web container:
To follow logs in real-time:
To view logs from all containers:
Log file locations¶
For more detailed debugging, you can access log files inside the container:
| Log | Description | Command |
|---|---|---|
| MediaWiki debug | Application debug log (see below) | docker compose exec web tail -f /var/log/mediawiki/debug.log |
| Apache error | PHP errors and Apache warnings | docker compose exec web tail -f /var/log/apache2/error_log.current |
| Apache access | HTTP request log | docker compose exec web tail -f /var/log/apache2/access_log.current |
Enabling the MediaWiki debug log¶
The MediaWiki debug log is the most useful log for debugging application issues, but it requires explicit configuration. Add this to a settings file (e.g., config/settings/global/Debug.php):
Then restart the container:
Accessing the database¶
To connect to the MySQL database directly:
Enter the root database password from your.env file when prompted.
Running commands inside containers¶
To run arbitrary commands inside the web container:
For example, to check PHP version:
To get a shell inside the container:
Common issues¶
Installation fails with "Canasta installation with the ID already exists"
- An installation with that ID is already registered. Use canasta list to see existing installations, or choose a different ID.
Cannot connect to Docker
- Ensure Docker is running: systemctl status docker
- Ensure your user has Docker access (on Linux: sudo usermod -aG docker $USER, then log out and back in)
Wiki not accessible after creation
- Check that containers are running: docker compose ps
- Verify the domain/URL configuration in config/wikis.yaml
- Check container logs for errors: docker compose logs web
Wiki not accessible on non-standard ports
- When using non-standard ports, the port must be included in the URL you use to access the wiki in your browser (e.g., https://localhost:8443, not https://localhost)
- The port must also appear in the URL in config/wikis.yaml (e.g., localhost:8443 or localhost:8443/wiki2)
- This applies to both path-based and subdomain-based wikis
SSL/TLS errors when running behind a reverse proxy or load balancer
- If your server is already behind something that terminates SSL (e.g. Cloudflare, nginx, a cloud load balancer), Caddy's automatic HTTPS will conflict with it. Add CADDY_AUTO_HTTPS=off to .env and restart. See Deploying behind a reverse proxy for details.
Permission denied errors
- Ensure your user is in the docker and www-data groups (on Linux: sudo usermod -aG docker,www-data $USER, then log out and back in)
- The docker group is needed for Docker access; the www-data group is needed because the web container runs as www-data and shares the config/ directory
- Ensure the installation directory has proper ownership