Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

token mechanism in CLI is documented? #416

Closed
MalloZup opened this issue Jul 3, 2019 · 2 comments
Closed

token mechanism in CLI is documented? #416

MalloZup opened this issue Jul 3, 2019 · 2 comments

Comments

@MalloZup
Copy link

MalloZup commented Jul 3, 2019

Hi all,

We were wondering if we we could use suseconnect CLI with a token.

I have done some research and I have found
https://github.com/SUSE/connect/search?p=2&q=token&unscoped_q=token

So it seems that there is a token way of donig things. However. this seems to be not reflected on the CLI output Documentation.


Usage: SUSEConnect [options]
Register SUSE Linux Enterprise installations with the SUSE Customer Center.
Registration allows access to software repositories (including updates)
and allows online management of subscriptions and organizations.

Manage subscriptions at https://scc.suse.com

    -p, --product [PRODUCT]  Specify a product for activation/deactivation. Only
                             one product can be processed at a time. Defaults to
                             the base SUSE Linux Enterprise product on this 
                             system. Product identifiers can be obtained
                             with `--list-extensions`.
                             Format: <name>/<version>/<architecture>
    -r, --regcode [REGCODE]  Subscription registration code for the product to
                             be registered.
                             Relates that product to the specified subscription,
                             and enables software repositories for that product.
    -d, --de-register        De-registers the system and base product, or in
                             conjunction with --product, a single extension, and
                             removes all its services installed by SUSEConnect.
                             After de-registration the system no longer consumes
                             a subscription slot in SCC.
        --instance-data  [path to file]
                             Path to the XML file holding the public key and
                             instance data for cloud registration with SMT.
    -e, --email <email>      Email address for product registration.
        --url [URL]          URL of registration server
                             (e.g. https://scc.suse.com).
                             Implies --write-config so that subsequent
                             invocations use the same registration server.
        --namespace [NAMESPACE]
                             Namespace option for use with SMT staging
                             environments.
    -s, --status             Get current system registration status in json
                             format.
        --status-text        Get current system registration status in text
                             format.
        --list-extensions    List all extensions and modules available for
                             installation on this system.
        --write-config       Write options to config file at /etc/SUSEConnect.
        --cleanup            Remove old system credentials and all zypper
                             services installed by SUSEConnect.
        --rollback           Revert the registration state in case of a failed
                             migration.

Common options:
        --root [PATH]        Path to the root folder, uses the same parameter
                             for zypper.
        --version            Print program version.
        --debug              Provide debug output.
    -h, --help               Show this message.
@lagartoflojo
Copy link
Contributor

Hi,
The mentions you see about "token" are actually about registration codes. Not token as in "API token".
In general, the auth mechanism used by SUSEConnect is HTTP Basic Auth, using the system credentials for that.
You can see our Swagger docs for details about what type of authentication each endpoint uses.

We do not support API tokens at this time.

@MalloZup
Copy link
Author

@lagartoflojo thx for clarification! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants