Forum Discussion

Sweatboy's avatar
Sweatboy
Icon for Nimbostratus rankNimbostratus
Sep 28, 2022

F5 DNS with cPanel Web Hosting Server

Hi,

 

We have a publicly accessible web hosting server backed by cPanel and currently we are using F5 to handle our DNS.

 

The problem that we are facing is when one of our end customer adds a Zone /DNS record INSIDE his cPanel account and everytime we have to manually check and add those records in F5 to make things work.

 

Is there a solution for this?.

  • Hi Sweatboy, are you using wideIPs on F5DNS for this, or managing it in ZoneRunner? If the former, that could be automated with iControlREST, if the latter, it can still be automated, but would require the SOAP version of iControl, which is aged but still supported. 

    • JRahm's avatar
      JRahm
      Icon for Admin rankAdmin

      An example messing around with the python bigsuds library:

      b = bigsuds.BIGIP(hostname='ltm3.test.local')
      rrs = b.Management.ResourceRecord.get_rrs([{'view_name': 'external', 'zone_name': 'test.local.'}])
      for rr in rrs[0]:
          print(rr)
          
      test.local.             500     IN      SOA     ltm3.test.local. hostmaster.ltm3.test.local. 2021091401 10800 3600 604800 60
      test.local.             0       IN      NS      ltm3.test.local.
      test.local.             3600    IN      CAA     0 issue test.local
      test.local.             3600    IN      CAA     0 issuewild test.local
      gslb_test.test.local.   0       IN      A       192.168.102.40
      ltm3.test.local.        0       IN      A       127.0.0.1
      w3.test.local.          3600    IN      A       10.0.0.102
      www.test.local.         0       IN      A       10.0.0.101
       
      b.Management.ResourceRecord.add_a(view_zones = [{'view_name': 'external', 'zone_name': 'test.local.'}],
                                        a_records = [[{'domain_name': 'w4.test.local.', 'ip_address': '10.0.0.104', 'ttl': 3600}]], sync_ptrs = [0])
      rrs = b.Management.ResourceRecord.get_rrs([{'view_name': 'external', 'zone_name': 'test.local.'}])
      for rr in rrs[0]:
          print(rr)
          
      test.local.             500     IN      SOA     ltm3.test.local. hostmaster.ltm3.test.local. 2021091402 10800 3600 604800 60
      test.local.             0       IN      NS      ltm3.test.local.
      test.local.             3600    IN      CAA     0 issue test.local
      test.local.             3600    IN      CAA     0 issuewild test.local
      gslb_test.test.local.   0       IN      A       192.168.102.40
      ltm3.test.local.        0       IN      A       127.0.0.1
      w3.test.local.          3600    IN      A       10.0.0.102
      w4.test.local.          3600    IN      A       10.0.0.104
      www.test.local.         0       IN      A       10.0.0.101
  • Did this help solve your issue? Let me know what approach you're going to take, happy to help!

  • Hello, we have been fighting with cPanel in a L3 configuration of F5 as the vendor for cPanel says that it does not support using a load balancer.  Is this for L2 inline only, or could this also work with cPanel as L3, on-a-stick deployment of F5?