{"action":"created","issue":{"url":"https://api.github.com/repos/mathieuruellan/docker-piwigo/issues/16","repository_url":"https://api.github.com/repos/mathieuruellan/docker-piwigo","labels_url":"https://api.github.com/repos/mathieuruellan/docker-piwigo/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/mathieuruellan/docker-piwigo/issues/16/comments","events_url":"https://api.github.com/repos/mathieuruellan/docker-piwigo/issues/16/events","html_url":"https://github.com/mathieuruellan/docker-piwigo/issues/16","id":372323340,"node_id":"MDU6SXNzdWUzNzIzMjMzNDA=","number":16,"title":"Piwigo with an Apache reverse proxy -> links broken","user":{"login":"cybermcm","id":13907742,"node_id":"MDQ6VXNlcjEzOTA3NzQy","avatar_url":"https://avatars1.githubusercontent.com/u/13907742?v=4","gravatar_id":"","url":"https://api.github.com/users/cybermcm","html_url":"https://github.com/cybermcm","followers_url":"https://api.github.com/users/cybermcm/followers","following_url":"https://api.github.com/users/cybermcm/following{/other_user}","gists_url":"https://api.github.com/users/cybermcm/gists{/gist_id}","starred_url":"https://api.github.com/users/cybermcm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cybermcm/subscriptions","organizations_url":"https://api.github.com/users/cybermcm/orgs","repos_url":"https://api.github.com/users/cybermcm/repos","events_url":"https://api.github.com/users/cybermcm/events{/privacy}","received_events_url":"https://api.github.com/users/cybermcm/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-10-21T14:58:05Z","updated_at":"2018-10-23T16:15:04Z","closed_at":null,"author_association":"NONE","body":"I'm trying to use this docker image with an Apache reverse proxy and a subpath, e.g. https://xyz.net/piwigo.\r\nIt works but not all of it. A lot of icons are broken and some links too. E.g. when I log in I'm getting redirected to the wrong url. Start page -> log in -> redirection to https://xyz.net instead of https://xyz.net/piwigo\r\n\r\ndocker compose file:\r\n```\r\npiwigo:\r\n  depends_on:\r\n   - sql\r\n  image: mathieuruellan/piwigo\r\n  container_name: piwigo\r\n  restart: always\r\n  ports:\r\n   - \"127.0.0.1:20008:80\"\r\n  volumes:\r\n   - /etc/timezone:/etc/timezone:ro\r\n   - /etc/localtime:/etc/localtime:ro\r\n   - /home/piwigo/data/galleries:/var/www/galleries\r\n   - /home/piwigo/data/local:/var/www/local\r\n   - /home/piwigo/data/plugins:/var/www/plugins\r\n   - /home/piwigo/data/themes:/var/www/themes\r\n   - /home/piwigo/cache:/var/www/_data/i\r\n   - /home/piwigo/upload:/var/www/upload\r\n   - /home/piwigo/log/var:/var/log\r\n   - /home/piwigo/log/piwigo:/var/log/apache2\r\n  networks:\r\n   - sql\r\n```\r\nrelevant apache config:\r\n```\r\nRewriteRule ^/piwigo$ /piwigo/ [R,L]\r\nProxyPass \"/piwigo\" \"http://localhost:20008\"\r\nProxyPassReverse \"/piwigo\" \"http://localhost:20008\"\r\n```\r\nAny ideas how to get this config working?"},"comment":{"url":"https://api.github.com/repos/mathieuruellan/docker-piwigo/issues/comments/432315019","html_url":"https://github.com/mathieuruellan/docker-piwigo/issues/16#issuecomment-432315019","issue_url":"https://api.github.com/repos/mathieuruellan/docker-piwigo/issues/16","id":432315019,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMjMxNTAxOQ==","user":{"login":"mathieuruellan","id":1267936,"node_id":"MDQ6VXNlcjEyNjc5MzY=","avatar_url":"https://avatars0.githubusercontent.com/u/1267936?v=4","gravatar_id":"","url":"https://api.github.com/users/mathieuruellan","html_url":"https://github.com/mathieuruellan","followers_url":"https://api.github.com/users/mathieuruellan/followers","following_url":"https://api.github.com/users/mathieuruellan/following{/other_user}","gists_url":"https://api.github.com/users/mathieuruellan/gists{/gist_id}","starred_url":"https://api.github.com/users/mathieuruellan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mathieuruellan/subscriptions","organizations_url":"https://api.github.com/users/mathieuruellan/orgs","repos_url":"https://api.github.com/users/mathieuruellan/repos","events_url":"https://api.github.com/users/mathieuruellan/events{/privacy}","received_events_url":"https://api.github.com/users/mathieuruellan/received_events","type":"User","site_admin":false},"created_at":"2018-10-23T16:15:04Z","updated_at":"2018-10-23T16:15:04Z","author_association":"OWNER","body":"Hi, \r\n\r\nI succeed with nginx. First time, you have to connect with `http://localhost/piwigo/install.php`\r\n\r\nHere is my docker-compose.yml\r\n`mysqlpiwigo:\r\n   image: mysql:5.5\r\n   volumes:\r\n      - /home/piwigo/mysql/:/var/lib/mysql\r\n   environment:\r\n      - MYSQL_ROOT_PASSWORD=MYROOTPASSWORD\r\n      - MYSQL_DATABASE=piwigo\r\n      - MYSQL_USER=piwigo\r\n      - MYSQL_PASSWORD=MYUSERPASSWORD\r\nnginx: \r\n  image: nginx:latest\r\n  container_name: production_nginx\r\n  volumes:\r\n    - ./nginx.conf:/etc/nginx/conf.d/default.conf\r\n  links:\r\n    - piwigo  \r\n  ports:\r\n    - 80:80\r\n    - 443:443\r\n\r\npiwigo:\r\n   image: mathieuruellan/piwigo\r\n   links:\r\n      - mysqlpiwigo:mysql\r\n   volumes:\r\n      - /home/piwigo/data/galleries:/var/www/galleries\r\n      - /home/piwigo/data/local:/var/www/local\r\n      - /home/piwigo/data/plugins:/var/www/plugins\r\n      - /home/piwigo/data/themes:/var/www/themes\r\n      - /home/piwigo/cache:/var/www/_data/i\r\n      - /home/piwigo/upload:/var/www/upload\r\n      - /var/log\r\n      - /var/log/piwigo:/var/log/apache2\r\n   hostname: piwigo\r\n   domainname: MYDOMAIN.COM\r\n`\r\n\r\nHere nginx.conf:\r\n\r\n`server {\r\n        listen 80 default_server;\r\n        listen [::]:80 default_server;\r\n\r\n        # SSL configuration\r\n        #\r\n        # listen 443 ssl default_server;\r\n        # listen [::]:443 ssl default_server;\r\n        #\r\n        # Note: You should disable gzip for SSL traffic.\r\n        # See: https://bugs.debian.org/773332\r\n        #\r\n        # Read up on ssl_ciphers to ensure a secure configuration.\r\n        # See: https://bugs.debian.org/765782\r\n        #\r\n        # Self signed certs generated by the ssl-cert package\r\n        # Don't use them in a production server!\r\n        #\r\n        # include snippets/snakeoil.conf;\r\n\r\n        server_name _;\r\n\r\n        location /piwigo {\r\n            proxy_pass http://piwigo:80/;   \r\n        }\r\n\r\n        # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000\r\n        #\r\n        #location ~ \\.php$ {\r\n        #       include snippets/fastcgi-php.conf;\r\n        #\r\n        #       # With php7.0-cgi alone:\r\n        #       fastcgi_pass 127.0.0.1:9000;\r\n        #       # With php7.0-fpm:\r\n        #       fastcgi_pass unix:/run/php/php7.0-fpm.sock;\r\n        #}\r\n\r\n        # deny access to .htaccess files, if Apache's document root\r\n        # concurs with nginx's one\r\n        #\r\n        #location ~ /\\.ht {\r\n        #       deny all;\r\n        #}\r\n}\r\n\r\n`\r\n"}}
{"actor":{"display_login":"mathieuruellan"}}