Class AbstractCLIApprover

  • All Implemented Interfaces:
    edu.uiuc.ncsa.security.core.Logable
    Direct Known Subclasses:
    CLIApprover

    public abstract class AbstractCLIApprover
    extends edu.uiuc.ncsa.security.util.cli.CLITool
    A command line approver. This has a couple of modes of operation.
    • Immediate updates for non-memory store. If you commit a change, it is done instantly
    • Polling mode. A directory is set aside to store the pending approvals. The server polls this at intervals and updates it store. This is especially useful for memory stores.

    Use

    You should invoke this from the command line and specify the server configuration file. You will have to run this with sufficient permissions to read that file, which probably means running this as root.

    Running it from maven

    To run this from maven directly, you need to follow these three steps:
    1. run mvn compile from the command line to compile it
    2. Issue

      mvn exec:java -Dexec.mainClass="edu.uiuc.ncsa.myproxy.oa4mp.server.util.CLIApprover" -Dexec.args="-cfg /path/to/config.xml -name config-name"
      r>
    3. Follow the on-screen prompts.

    Custom versions

    This requires the right runtime ServiceEnvironment, which is normally loaded using a ConfigurationLoader.

    Created by Jeff Gaynor
    on 2/24/12 at 2:40 PM

    • Constructor Detail

      • AbstractCLIApprover

        public AbstractCLIApprover()
    • Method Detail

      • doIt

        public void doIt()
                  throws Exception
        Specified by:
        doIt in class edu.uiuc.ncsa.security.util.cli.CLITool
        Throws:
        Exception
      • formatClient

        protected String formatClient​(Client client)
      • getComponentName

        public String getComponentName()
        Specified by:
        getComponentName in class edu.uiuc.ncsa.security.util.cli.CLITool
      • getOptions

        protected org.apache.commons.cli.Options getOptions()
        Overrides:
        getOptions in class edu.uiuc.ncsa.security.util.cli.CLITool
      • help

        public void help()
        Specified by:
        help in class edu.uiuc.ncsa.security.util.cli.CLITool