PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Saturday, June 25, 2022

[FIXED] What is needed to run Traefik main reverse-proxy under a subdomain?

 June 25, 2022     dns, reverse-proxy, subdomain, traefik     No comments   

Issue

I have successfully setup Traefik under a top-level domain such as example.com, which is used as a main reverse proxy in docker-swarm with multiple containers/stacks. This way, I could automatically point traefik to subdomains received from docker containerized services, e.g. service1.example.com, service2.example.com etc.

My question is, would such a setup also work if I run traefik in a subdomain, e.g. app.example.com, where example.com is hosted on a completely separate server not managed by traefik? I want my containers to be reachable similarly in those subdomains, e.g. service1.app.example.com, service2.app.example.com, wherein subdomains (service1, service2) are managed by traefik running at app.example.com.

I know that I needed a DNS A record to point to my traefik-instance in example 1, can I do something similar with a subdomain or would this work differently?

Many thanks for hints!


Solution

This will work without a problem, as long as your domain provider doesn't restrict this.

You will have an A record with *.app and point it to the Traefik server ip



Answered By - Tarun Lalwani
Answer Checked By - Pedro (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing