Hi,
i use Piwigo 11.4 on AWS behind a firewall and a ALB Loadbalancer. If a upload a image, i get a html 504 error. The reason is, that after the upload piwigo tries in the function fetchRemote to reach the file via curl or fopen. But the url is only available from outside of the firewall and not from inside from the server. So i see SYN_SENT packets and after a timeout, the apache sends a html 504 error code.
If i deactivate the curl and fopen check, it seems to working perfect.
Now i have some questions and it would be great, if someone has a hint for me:
Is there a recommendation for using Piwigo behind a firewall and load balancer?
Is there a configuration to deactivate the curl and fopen check?
Is it safe to deactivate the curl and fopen check?
Is there a way to configure the server url? So that not the firewall address but the internal address is used for the checks?
Hi,
i use Piwigo 11.4 on AWS behind a firewall and a ALB Loadbalancer. If a upload a image, i get a html 504 error. The reason is, that after the upload piwigo tries in the function fetchRemote to reach the file via curl or fopen. But the url is only available from outside of the firewall and not from inside from the server. So i see SYN_SENT packets and after a timeout, the apache sends a html 504 error code.
If i deactivate the curl and fopen check, it seems to working perfect.
Now i have some questions and it would be great, if someone has a hint for me:
1. Is there a recommendation for using Piwigo behind a firewall and load balancer?
2. Is there a configuration to deactivate the curl and fopen check?
3. Is it safe to deactivate the curl and fopen check?
4. Is there a way to configure the server url? So that not the firewall address but the internal address is used for the checks?
Thank you very much.
Best regards, Holger Koch
Piwigo 11.4.0
Operating system: Amazon Linux 2
PHP: 7.2.34 (Show info) [2021-04-21 07:10:20]
MySQL: 8.0.20 [2021-04-21 07:10:20]
Graphics Library: External ImageMagick 6.9.10-68
<!-- github-sync-id:863546239 -->
My setup is similar - behind a firewall and with NAT. I get same behaviour: A timeout when fetchRemote is not commented.
As you mentioned fetchRemote tries to connect to the external IP, so I implemented NAT reflecting with following nftables rule: ip daddr != 172.28.0.0/16 fib daddr type local tcp dport 80 dnat to 172.28.2.10:80
This allows fetchRemote to connect via the external IP (10.0.16.1 in my case) to the internal service.
However, now the connection gets directly established (no timeout) and data is transferred but I have following error.
Hello,
My setup is similar - behind a firewall and with NAT. I get same behaviour: A timeout when `fetchRemote` is not commented.
As you mentioned `fetchRemote` tries to connect to the external IP, so I implemented `NAT reflecting` with following nftables rule:
`ip daddr != 172.28.0.0/16 fib daddr type local tcp dport 80 dnat to 172.28.2.10:80`
This allows `fetchRemote` to connect via the external IP (10.0.16.1 in my case) to the internal service.
However, now the connection gets directly established (no timeout) and data is transferred but I have following error.


I hope this helps.
Thomas
```
Piwigo 11.5.0
Operating system: Linux
PHP: 7.4.19 (Show info) [2021-06-09 13:33:43]
MySQL: 5.5.5-10.3.27-MariaDB-0+deb10u1 [2021-06-09 13:33:43]
Graphics Library: ImageMagick 7.0.11-13
```
<!-- github-comment-id:857619895 -->
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Hi,
i use Piwigo 11.4 on AWS behind a firewall and a ALB Loadbalancer. If a upload a image, i get a html 504 error. The reason is, that after the upload piwigo tries in the function fetchRemote to reach the file via curl or fopen. But the url is only available from outside of the firewall and not from inside from the server. So i see SYN_SENT packets and after a timeout, the apache sends a html 504 error code.
If i deactivate the curl and fopen check, it seems to working perfect.
Now i have some questions and it would be great, if someone has a hint for me:
Thank you very much.
Best regards, Holger Koch
Piwigo 11.4.0
Operating system: Amazon Linux 2
PHP: 7.2.34 (Show info) [2021-04-21 07:10:20]
MySQL: 8.0.20 [2021-04-21 07:10:20]
Graphics Library: External ImageMagick 6.9.10-68
Hello,
My setup is similar - behind a firewall and with NAT. I get same behaviour: A timeout when
fetchRemoteis not commented.As you mentioned
fetchRemotetries to connect to the external IP, so I implementedNAT reflectingwith following nftables rule:ip daddr != 172.28.0.0/16 fib daddr type local tcp dport 80 dnat to 172.28.2.10:80This allows
fetchRemoteto connect via the external IP (10.0.16.1 in my case) to the internal service.However, now the connection gets directly established (no timeout) and data is transferred but I have following error.
I hope this helps.
Thomas