F5Networks / f5-appsvcs-templates

F5 BIG-IP Application Service Templates (FAST)
Apache License 2.0
32 stars 13 forks source link

TargetHost not working together with FAST Template #138

Closed DahlPatric closed 7 months ago

DahlPatric commented 10 months ago

Environment

Summary

When posting input json body towards endpoint /mgmt/shared/fast/applications, AS3 not picking up TargetHost and forward request. Doing similar but with complete AS3 declaration towards /mgmt/shared/appsvcs/declare request got forwarded.

Steps To Reproduce

POST https://192.168.1.10/mgmt/shared/fast/applications

Input:

{
"name":"myTemplate/Standard",
"parameters":{
"targetHost":"192.168.1.11",
"tenant_name":"",
"application_name":"app-MyAppABC",
"app-id":"app-MyAppABC",
"virtual_port":443,
"virtual_address":"1.1.1.1",
"service_port":443,
"members": [
              {
                "servicePort": 443,
                "hostname": "www.cnn.com",
                "addressDiscovery": "fqdn"
              },
              {
                "servicePort": 443,
                "hostname": "www.google.com",
                "addressDiscovery": "fqdn"
              }
            ]
}
}

FAST Template:

{
    "$schema": "https://raw.githubusercontent.com/F5Networks/f5-appsvcs-extension/master/schema/latest/as3-schema.json",
    "class": "AS3",
    "action": "deploy",
    "targetHost": "{{targethost}}",
    "targetUsername": "username",
    "targetPassphrase": "password",

Expected Behavior / Actual Behavior

Application should appear at "targetHost":"192.168.1.11", but instead shown up in machine posting the request. (192.168.1.10)

Additional Notes

Request have been sent to AS3 GitHub where conclusion was to not use lowercase for targetHost. https://github.com/F5Networks/f5-appsvcs-extension/issues/768

shyawnkarim commented 10 months ago

Thanks for submitting this issue. It is now being tracked internally with ID, EC-384.

joelkeener commented 7 months ago

The targetHost property of the ADC class is ignored by FAST. This fact will be documented in the next release of FAST.