[ 
https://issues.apache.org/jira/browse/SOLR-8440?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16007448#comment-16007448
 ] 

Ishan Chattopadhyaya commented on SOLR-8440:
--------------------------------------------

bq. Problem with SOLR_PID_DIR and SOLR_TIP/bin is that it does not support an 
install with multiple instances run from same binaries.

Isn't it the case that all of those instances will be part of the same 
SolrCloud cluster, and hence they *should* have the same basicAuth.conf? 
However, when this feature is extended to cover standalone mode, then we could 
suffix the file with a port (or somehow figure out how to use a SOLR_HOME).

bq. Guess we have to move the SOLR_HOME resolution lines higher up in the script
Trying to use SOLR_HOME by "moving" the logic up the logic would break the 
resolution of the SOLR_HOME in the case of a "start" command. I am trying to do 
it both higher up as well as where it is currently done, but that also is 
breaking the "start" command. Also, the whole $SOLR_SERVER_DIR block also needs 
to be copied/moved higher up, since $SOLR_HOME depends on that. Here's that 
block:
{code}
            if [[ "$2" == "." || "$2" == "./" || "$2" == ".." || "$2" == "../" 
]]; then
              SOLR_SERVER_DIR="$(pwd)/$2"
            else
              # see if the arg value is relative to the tip vs full path
              if [[ "$2" != /* ]] && [[ -d "$SOLR_TIP/$2" ]]; then
                SOLR_SERVER_DIR="$SOLR_TIP/$2"
              else
                SOLR_SERVER_DIR="$2"
              fi
            fi
{code}

Needless to say, trying to use SOLR_HOME is proving quite tricky. I am still 
trying, though..

> Script support for enabling basic auth
> --------------------------------------
>
>                 Key: SOLR-8440
>                 URL: https://issues.apache.org/jira/browse/SOLR-8440
>             Project: Solr
>          Issue Type: New Feature
>          Components: scripts and tools
>            Reporter: Jan Høydahl
>            Assignee: Ishan Chattopadhyaya
>              Labels: authentication, security
>             Fix For: 6.6, master (7.0)
>
>         Attachments: SOLR-8440-follow-up.patch, SOLR-8440.patch, 
> SOLR-8440.patch, SOLR-8440.patch, SOLR-8440.patch, SOLR-8440.patch, 
> SOLR-8440.patch, SOLR-8440.patch, SOLR-8440.patch
>
>
> Now that BasicAuthPlugin will be able to work without an AuthorizationPlugin 
> (SOLR-8429), it would be sweet to provide a super simple way to "Password 
> protect Solr"™ right from the command line:
> {noformat}
> bin/solr basicAuth -adduser -user solr -pass SolrRocks
> {noformat}
> It would take the mystery out of enabling one single password across the 
> board. The command would do something like this
> # Check if HTTPS is enabled, and if not, print a friendly warning
> # Check if {{/security.json}} already exists
> ## NO => create one with only plugin class defined
> ## YES => Abort if exists but plugin is not {{BasicAuthPlugin}}
> # Using security REST API, add the new user



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to