zowe / zowe-cli

Zowe CLI
Eclipse Public License 2.0
113 stars 87 forks source link

Support logging in to multiple APIML instances per config file #1705

Closed t1m0thyj closed 1 month ago

t1m0thyj commented 1 year ago

Currently we only support logging in to the APIML for base profiles, and there can only be one active base profile per team config file. If nested profiles like the example below are defined, users may want to log in to multiple APIML instances per team config file. Either Zowe CLI should also support this scenario with zowe auth login, or we should document it as a known limitation.

{
    "$schema": "./zowe.schema.json",
    "profiles": {
        "lpar1": {
            "profiles": {
                "zosmf": {
                    "type": "zosmf",
                    "properties": {
                        "basePath": "/ibmzosmf/api/v1"
                    }
                }
            },
            "properties": {
                "host": "example1.com",
                "port": 7554,
                "rejectUnauthorized": true,
                "tokenType": "apimlAuthenticationToken"
            },
            "secure": [
                "tokenValue"
            ]
        },
        "lpar2": {
            "profiles": {
                "zosmf": {
                    "type": "zosmf",
                    "properties": {
                        "basePath": "/ibmzosmf/api/v1"
                    }
                }
            },
            "properties": {
                "host": "example2.com",
                "port": 7554,
                "rejectUnauthorized": true,
                "tokenType": "apimlAuthenticationToken"
            },
            "secure": [
                "tokenValue"
            ]
        }
    },
    "defaults": {
        "zosmf": "lpar1.zosmf"
    },
    "autoStore": true
}
github-actions[bot] commented 1 year ago

Thank you for raising this enhancement request. The community has 90 days to vote on it. If the enhancement receives at least 5 upvotes, it is added to our development backlog. If it receives fewer votes, the issue is closed.

github-actions[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

t1m0thyj commented 2 months ago

Zowe CLI may already support this when the --base-profile option is specified on the auth login command. We should confirm this and document the process if it works.