CLI not taking IF statements in batch mode in EAP 6/7.

Solution Verified - Updated -

Issue

  • We are running our security hardening CLI script against standalone-ha.xml, which includes the ajp protocol.
  • When we wrapped the add protocol with an if statemnt the batch failed stating, "if is not allowed while in batch mode." I thought if statements were included in batch.

Environment

  • Enterprise Application Platform (EAP)
    • 6.x
    • 7.x
  • Command Line Interface (CLI)

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content