F5Networks / f5-appsvcs-extension

F5 BIG-IP Application Services 3 Extension
Apache License 2.0
164 stars 53 forks source link

TargetHost not working #768

Closed DahlPatric closed 11 months ago

DahlPatric commented 11 months ago

Environment

Summary

From Postman I'll try to push my AS3 declaration to one bigip running AS3 then later with targetHost relay to another. This is not working, is thought it should work this way in if it's not.

Steps To Reproduce

Steps to reproduce the behavior:

  1. Postman POST https://192.168.1.2/mgmt/shared/appsvcs/declare

  2. Submit the following declaration:

    {
    "$schema": "https://raw.githubusercontent.com/F5Networks/f5-appsvcs-extension/master/schema/latest/as3-schema.json",
    "class": "AS3",
    "action": "deploy",
    "targethost": "192.168.1.10",
    "persist": true,
    "declaration": {
      "class": "ADC",
      "schemaVersion": "3.33.0",
      "label": "Version 1.0",
      "remark": "Standard HTTPS application with predictive-node pool",
      "constants": {
        "class": "Constants",
        "timestamp": "2023-05-11T13:59:00Z",
        "version": 1.0
      },
  3. Observe the following error response: None

Expected Behavior

Declaration should appears on there "targetHost": points.

Actual Behavior

Declaration posts where I'm posting my request with Postman,

dstokesf5 commented 11 months ago

You may also need to specify targetPort, targetUsername, and targetPassphrase.

tpitkinf5 commented 11 months ago

Adding to @dstokesf5 comment, make sure you're using the property targetHost. If you're accidently leaving it all lowercase (targethost), AS3 will ignore the property and try to configure your current machine instead of the target one.

DahlPatric commented 11 months ago

Thanks @dstokesf5 & @tpitkinf5 you were both right. targetHost, targetUsername, and targetPassphrase all need to exist and in correct format.

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

Best regards Patric