Production deployment leads to Internal Server Error
Opened this issue · 4 comments
I'm having some trouble using the production deployment process. After cloning the repo and running run.sh on a fresh DigitalOcean Ubuntu 16.04.3 x64 droplet, visiting the app host resulted in "Internal Server Error" (HTTPS worked, though).
Can't find any documentation on where error logs might be, but there is nothing pertinent in /var/log/nginx/error.log. I restarted the entire server, hoping maybe webrecorder would be in the startup scripts, then simply got a 404 error at the webrecorder URL. I wasn't really sure what to do next, but I found ~/webrecorder and I tried running ./rebuild.sh, which didn't seem to do anything (still a 404). I have reviewed any and all documentation (which I think is just README.md) and I'm not clear what to do next.
Any additional documentation would be most appreciated—even if just instructions on (a) how to launch webrecorder and (b) where logs are located. Thanks!
Log with redactions attached.
Hi, thanks for including the logs, it looks like Ansible succeeded, but there is an issue with the app itself. The basic Webrecorder install instructions are on the main webrecorder repo.
The logs are managed by Docker.
You can run docker-compose logs app
too see the logs for the main application.
Based on the other issues in the repo, I assume you were you able to resolve this issue and get Webrecorder running? If so, what was the issue?
We can definitely improve the docs and add pointers on where to go to look for more info.
In a subsequent install, the “internal server error” is replaced with the default “Welcome to nginx” page:
TASK [geerlingguy.docker : Install Docker.] ******************************************************************************************************************************** fatal: [localhost]: FAILED! => {"changed": false, "failed": true, "msg": "No package matching 'docker-ce' is available"}
$ docker-compose logs app Traceback (most recent call last): File "/usr/local/bin/docker-compose", line 7, in <module> from compose.cli.main import main File "/usr/local/lib/python2.7/dist-packages/compose/cli/main.py", line 17, in <module> from . import errors File "/usr/local/lib/python2.7/dist-packages/compose/cli/errors.py", line 11, in <module> from docker.errors import APIError File "/usr/local/lib/python2.7/dist-packages/docker/__init__.py", line 2, in <module> from .api import APIClient File "/usr/local/lib/python2.7/dist-packages/docker/api/__init__.py", line 2, in <module> from .client import APIClient File "/usr/local/lib/python2.7/dist-packages/docker/api/client.py", line 11, in <module> from .build import BuildApiMixin File "/usr/local/lib/python2.7/dist-packages/docker/api/build.py", line 9, in <module> from .. import utils File "/usr/local/lib/python2.7/dist-packages/docker/utils/__init__.py", line 2, in <module> from .build import tar, exclude_paths File "/usr/local/lib/python2.7/dist-packages/docker/utils/build.py", line 5, in <module> from .utils import create_archive File "/usr/local/lib/python2.7/dist-packages/docker/utils/utils.py", line 18, in <module> from .. import tls File "/usr/local/lib/python2.7/dist-packages/docker/tls.py", line 5, in <module> from .transport import SSLAdapter File "/usr/local/lib/python2.7/dist-packages/docker/transport/__init__.py", line 3, in <module> from .ssladapter import SSLAdapter File "/usr/local/lib/python2.7/dist-packages/docker/transport/ssladapter.py", line 21, in <module> from backports.ssl_match_hostname import match_hostname ImportError: No module named ssl_match_hostname
This appears to be an error installing Docker.. but it worked the first time?
We haven't had a chance to test on DigitalOcean, but make sure you have latest Ansible and could you try again on a brand new instance?
There are actually 2 nginx instances, once in Docker, where the logs are accessible via docker-compose logs nginx
and the other running outside, set up by Ansible, to handle SSL.
The logs for that nginx should be in the standard /var/log/nginx/access.log
and /var/log/nginx/error.log