Gateway time-out 504 or 502what causes 504 Gateway Time-out in mod_jk with tomcat7 & apache2?nginx 504 gateway timeoutNGINX: 504 Gateway Time-out504 Gateway Time-outCloudflare Bad Gateway 502 errorAzure Application Gateway 502 errormpdf 504 gateway timeout errorInternal and external services running behind Traefik in Docker Swarm modeSpring Boot - 504 gateway timeoutUp-in registry Gateway has timed out and not accepting requests. 504
Should I avoid hard-packed crusher dust trails with my hybrid?
Using "subway" as name for London Underground?
What's up with this leaf?
Why doesn't Adrian Toomes give up Spider-Man's identity?
Why didn't Voldemort recognize that Dumbledore was affected by his curse?
How can I tell the difference between unmarked sugar and stevia?
SOQL Not Recognizing Field?
Medieval flying castle propulsion
Determining fair price for profitable mobile app business
Why VGA framebuffer was limited to 64kB window?
Is a lack of character descriptions a problem?
How can I end combat quickly when the outcome is inevitable?
How to forge a multi-part weapon?
How to tell your grandparent to not come to fetch you with their car?
Project Euler #7 10001st prime in C++
Why was the Sega Genesis marketed as a 16-bit console?
Taxi Services at Didcot
What makes Ada the language of choice for the ISS's safety-critical systems?
Thread Pool C++ Implementation
Winning Strategy for the Magician and his Apprentice
This riddle is not to see but to solve
Why is only the fundamental frequency component said to give useful power?
Can U.S. Tax Forms Be Legally HTMLified?
1980s live-action movie where individually-coloured nations on clouds fight
Gateway time-out 504 or 502
what causes 504 Gateway Time-out in mod_jk with tomcat7 & apache2?nginx 504 gateway timeoutNGINX: 504 Gateway Time-out504 Gateway Time-outCloudflare Bad Gateway 502 errorAzure Application Gateway 502 errormpdf 504 gateway timeout errorInternal and external services running behind Traefik in Docker Swarm modeSpring Boot - 504 gateway timeoutUp-in registry Gateway has timed out and not accepting requests. 504
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
Impossible to connect to frontends with HTTPS with a specific domain: Error 502 or Error 504 (db or webmail)
I am using 3 YAML files:
1 for traefik
1 for subdomain 1, 1 for subdomain 2
Traefik and domain 1 configuration are OK, the problem is on subdomain2. The network configuration in docker-compose is nearly the same between subdomain1 et subdomain2. Restarting and recreating the container doesn't change anything.
traefik.yaml
version: '3'
networks:
internal:
internal: true
external: false
prometheus:
external:
name: dockerprometheus_back-tier
services:
reverse-proxy:
image: traefik #The official Traefik docker image
container_name: traefik
command: --api --docker --docker.domain=domain.local
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
command: --api --docker --docker.domain=domain.local #Enables the web UI and tells Træfik to listen to docker
# command: --web --web.metrics.prometheus --web.metrics.prometheus.buckets="0.1,0.3,1.2,5.0" --docker --docker.domain=domain.local --logLevel=DEBUG
networks:
- prometheus
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
sub1.yaml
:
version: '3'
networks:
onlykoreainternal:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
sub2.yaml
version: '3'
networks:
mail_network:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
# extra_hosts: - Required for external database (on other server or for local databases on host without docker)
# - "mailmariadb:xx.xx.xx.xx" - Replace with IP address of MariaDB server
# - "redis:xx.xx.xx.xx" - Replace with IP address of Redis server
ports:
- "25:25" # SMTP - Required
# - "110:110" # POP3 STARTTLS - Optional - For webmails/desktop clients
- "143:143" # IMAP STARTTLS - Optional - For webmails/desktop clients
# - "465:465" # SMTPS SSL/TLS - Optional - Enabled for compatibility reason, otherwise disabled
- "587:587" # Submission STARTTLS - Optional - For webmails/desktop clients
- "993:993" # IMAPS SSL/TLS - Optional - For webmails/desktop clients
# - "995:995" # POP3S SSL/TLS - Optional - For webmails/desktop clients
- "4190:4190" # SIEVE STARTTLS - Optional - Recommended for mail filtering
env_file:
- mail.env
environment:
- DBPASS=$DATABASE_USER_PASSWORD # MariaDB database password (required)
- RSPAMD_PASSWORD=$RSPAMD_PASSWORD # Rspamd WebUI password (required)
@
Same declaration in traefik.tom for sub1 and sub2 for DNS.
Have you any ideas about the bug?
Change the network inside the container (1 private and 1 host for each front-end, only 1 private/internal for databases).
Check logs (nothing interresting)
cloudflare gateway traefik
add a comment |
Impossible to connect to frontends with HTTPS with a specific domain: Error 502 or Error 504 (db or webmail)
I am using 3 YAML files:
1 for traefik
1 for subdomain 1, 1 for subdomain 2
Traefik and domain 1 configuration are OK, the problem is on subdomain2. The network configuration in docker-compose is nearly the same between subdomain1 et subdomain2. Restarting and recreating the container doesn't change anything.
traefik.yaml
version: '3'
networks:
internal:
internal: true
external: false
prometheus:
external:
name: dockerprometheus_back-tier
services:
reverse-proxy:
image: traefik #The official Traefik docker image
container_name: traefik
command: --api --docker --docker.domain=domain.local
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
command: --api --docker --docker.domain=domain.local #Enables the web UI and tells Træfik to listen to docker
# command: --web --web.metrics.prometheus --web.metrics.prometheus.buckets="0.1,0.3,1.2,5.0" --docker --docker.domain=domain.local --logLevel=DEBUG
networks:
- prometheus
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
sub1.yaml
:
version: '3'
networks:
onlykoreainternal:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
sub2.yaml
version: '3'
networks:
mail_network:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
# extra_hosts: - Required for external database (on other server or for local databases on host without docker)
# - "mailmariadb:xx.xx.xx.xx" - Replace with IP address of MariaDB server
# - "redis:xx.xx.xx.xx" - Replace with IP address of Redis server
ports:
- "25:25" # SMTP - Required
# - "110:110" # POP3 STARTTLS - Optional - For webmails/desktop clients
- "143:143" # IMAP STARTTLS - Optional - For webmails/desktop clients
# - "465:465" # SMTPS SSL/TLS - Optional - Enabled for compatibility reason, otherwise disabled
- "587:587" # Submission STARTTLS - Optional - For webmails/desktop clients
- "993:993" # IMAPS SSL/TLS - Optional - For webmails/desktop clients
# - "995:995" # POP3S SSL/TLS - Optional - For webmails/desktop clients
- "4190:4190" # SIEVE STARTTLS - Optional - Recommended for mail filtering
env_file:
- mail.env
environment:
- DBPASS=$DATABASE_USER_PASSWORD # MariaDB database password (required)
- RSPAMD_PASSWORD=$RSPAMD_PASSWORD # Rspamd WebUI password (required)
@
Same declaration in traefik.tom for sub1 and sub2 for DNS.
Have you any ideas about the bug?
Change the network inside the container (1 private and 1 host for each front-end, only 1 private/internal for databases).
Check logs (nothing interresting)
cloudflare gateway traefik
add a comment |
Impossible to connect to frontends with HTTPS with a specific domain: Error 502 or Error 504 (db or webmail)
I am using 3 YAML files:
1 for traefik
1 for subdomain 1, 1 for subdomain 2
Traefik and domain 1 configuration are OK, the problem is on subdomain2. The network configuration in docker-compose is nearly the same between subdomain1 et subdomain2. Restarting and recreating the container doesn't change anything.
traefik.yaml
version: '3'
networks:
internal:
internal: true
external: false
prometheus:
external:
name: dockerprometheus_back-tier
services:
reverse-proxy:
image: traefik #The official Traefik docker image
container_name: traefik
command: --api --docker --docker.domain=domain.local
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
command: --api --docker --docker.domain=domain.local #Enables the web UI and tells Træfik to listen to docker
# command: --web --web.metrics.prometheus --web.metrics.prometheus.buckets="0.1,0.3,1.2,5.0" --docker --docker.domain=domain.local --logLevel=DEBUG
networks:
- prometheus
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
sub1.yaml
:
version: '3'
networks:
onlykoreainternal:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
sub2.yaml
version: '3'
networks:
mail_network:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
# extra_hosts: - Required for external database (on other server or for local databases on host without docker)
# - "mailmariadb:xx.xx.xx.xx" - Replace with IP address of MariaDB server
# - "redis:xx.xx.xx.xx" - Replace with IP address of Redis server
ports:
- "25:25" # SMTP - Required
# - "110:110" # POP3 STARTTLS - Optional - For webmails/desktop clients
- "143:143" # IMAP STARTTLS - Optional - For webmails/desktop clients
# - "465:465" # SMTPS SSL/TLS - Optional - Enabled for compatibility reason, otherwise disabled
- "587:587" # Submission STARTTLS - Optional - For webmails/desktop clients
- "993:993" # IMAPS SSL/TLS - Optional - For webmails/desktop clients
# - "995:995" # POP3S SSL/TLS - Optional - For webmails/desktop clients
- "4190:4190" # SIEVE STARTTLS - Optional - Recommended for mail filtering
env_file:
- mail.env
environment:
- DBPASS=$DATABASE_USER_PASSWORD # MariaDB database password (required)
- RSPAMD_PASSWORD=$RSPAMD_PASSWORD # Rspamd WebUI password (required)
@
Same declaration in traefik.tom for sub1 and sub2 for DNS.
Have you any ideas about the bug?
Change the network inside the container (1 private and 1 host for each front-end, only 1 private/internal for databases).
Check logs (nothing interresting)
cloudflare gateway traefik
Impossible to connect to frontends with HTTPS with a specific domain: Error 502 or Error 504 (db or webmail)
I am using 3 YAML files:
1 for traefik
1 for subdomain 1, 1 for subdomain 2
Traefik and domain 1 configuration are OK, the problem is on subdomain2. The network configuration in docker-compose is nearly the same between subdomain1 et subdomain2. Restarting and recreating the container doesn't change anything.
traefik.yaml
version: '3'
networks:
internal:
internal: true
external: false
prometheus:
external:
name: dockerprometheus_back-tier
services:
reverse-proxy:
image: traefik #The official Traefik docker image
container_name: traefik
command: --api --docker --docker.domain=domain.local
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
command: --api --docker --docker.domain=domain.local #Enables the web UI and tells Træfik to listen to docker
# command: --web --web.metrics.prometheus --web.metrics.prometheus.buckets="0.1,0.3,1.2,5.0" --docker --docker.domain=domain.local --logLevel=DEBUG
networks:
- prometheus
ports:
- "80:80" #The HTTP port
- "443:443" #The HTTPS port
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:mail.prekre.com
- traefik.port=8080
- traefik.docker.network=prometheus
expose:
- "8090"
env_file:
- ./prekre.env
volumes:
- /var/run/docker.sock:/var/run/docker.sock #So that Traefik can listen to the Docker events
- ./traefik2.toml:/traefik.toml
- ./acme.json:/acme.json
restart: always
sub1.yaml
:
version: '3'
networks:
onlykoreainternal:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
sub2.yaml
version: '3'
networks:
mail_network:
driver: bridge
external: false
internal: true
prometheus:
external:
name: dockerprometheus_back-tier
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
services:
mailserver:
image: hardware/mailserver:$MAILSERVER_DOCKER_TAG
container_name: mailserver
restart: $RESTART_MODE
domainname: $MAILSERVER_DOMAIN # Mail server A/MX/FQDN & reverse PTR = mail.domain.tld.
hostname: $MAILSERVER_HOSTNAME
labels:
- traefik.enable=true
- traefik.frontend.rule=Host:spam.$MAILSERVER_DOMAIN
- traefik.port=80
- traefik.docker.network=prometheus
# extra_hosts: - Required for external database (on other server or for local databases on host without docker)
# - "mailmariadb:xx.xx.xx.xx" - Replace with IP address of MariaDB server
# - "redis:xx.xx.xx.xx" - Replace with IP address of Redis server
ports:
- "25:25" # SMTP - Required
# - "110:110" # POP3 STARTTLS - Optional - For webmails/desktop clients
- "143:143" # IMAP STARTTLS - Optional - For webmails/desktop clients
# - "465:465" # SMTPS SSL/TLS - Optional - Enabled for compatibility reason, otherwise disabled
- "587:587" # Submission STARTTLS - Optional - For webmails/desktop clients
- "993:993" # IMAPS SSL/TLS - Optional - For webmails/desktop clients
# - "995:995" # POP3S SSL/TLS - Optional - For webmails/desktop clients
- "4190:4190" # SIEVE STARTTLS - Optional - Recommended for mail filtering
env_file:
- mail.env
environment:
- DBPASS=$DATABASE_USER_PASSWORD # MariaDB database password (required)
- RSPAMD_PASSWORD=$RSPAMD_PASSWORD # Rspamd WebUI password (required)
@
Same declaration in traefik.tom for sub1 and sub2 for DNS.
Have you any ideas about the bug?
Change the network inside the container (1 private and 1 host for each front-end, only 1 private/internal for databases).
Check logs (nothing interresting)
cloudflare gateway traefik
cloudflare gateway traefik
edited Mar 24 at 19:44
double-beep
3,13151632
3,13151632
asked Mar 24 at 17:31
Kim Le joncKim Le jonc
134
134
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55326548%2fgateway-time-out-504-or-502%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55326548%2fgateway-time-out-504-or-502%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown