<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openstack/python-swiftclient.git/swiftclient/authv1.py, branch stable/ocata</title>
<subtitle>opendev.org: openstack/python-swiftclient.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-swiftclient.git/'/>
<entry>
<title>Add v1password keystoneauth plugin</title>
<updated>2016-10-23T23:52:37+00:00</updated>
<author>
<name>Tim Burke</name>
<email>tim.burke@gmail.com</email>
</author>
<published>2016-04-01T22:12:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-swiftclient.git/commit/?id=a38efb6031efda7a076886066b6993cdb144f6a3'/>
<id>a38efb6031efda7a076886066b6993cdb144f6a3</id>
<content type='text'>
This lets us use Keystone sessions against endpoints like swauth and
tempauth with code like:

    import keystoneauth1.loading
    import keystoneauth1.session
    import swiftclient

    loader = keystoneauth1.loading.get_plugin_loader('v1password')
    auth_plugin = loader.load_from_options(
        auth_url='http://saio:8080/auth/v1.0',
        username='test:tester',
        password='testing')
    keystone_session = keystoneauth1.session.Session(auth_plugin)

    conn = swiftclient.Connection(session=keystone_session)

The plugin includes an optional project_name option, which may be used
to override the swift account from the storage url that was returned.
Additionally, it includes enough infrastructure to support some commands
in python-openstackclient&gt;=3.0:

    export OS_AUTH_TYPE=v1password
    export OS_AUTH_URL=http://saio:8080/auth/v1.0
    export OS_PROJECT_NAME=AUTH_test2
    export OS_USERNAME=test:tester
    export OS_PASSWORD=testing

    openstack token issue
    openstack catalog list
    openstack catalog show object-store
    openstack object store account show
    openstack container list
    openstack container create &lt;container&gt;
    openstack container save &lt;container&gt;
    openstack container show &lt;container&gt;
    openstack container delete &lt;container&gt;
    openstack object list &lt;container&gt;
    openstack object create &lt;container&gt; &lt;file&gt;
    openstack object save &lt;container&gt; &lt;object&gt;
    opsentack object show &lt;container&gt; &lt;object&gt;
    openstack object delete &lt;container&gt; &lt;object&gt;

Change-Id: Ia963dc44415f72a6518227e86d9528a987e07491
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This lets us use Keystone sessions against endpoints like swauth and
tempauth with code like:

    import keystoneauth1.loading
    import keystoneauth1.session
    import swiftclient

    loader = keystoneauth1.loading.get_plugin_loader('v1password')
    auth_plugin = loader.load_from_options(
        auth_url='http://saio:8080/auth/v1.0',
        username='test:tester',
        password='testing')
    keystone_session = keystoneauth1.session.Session(auth_plugin)

    conn = swiftclient.Connection(session=keystone_session)

The plugin includes an optional project_name option, which may be used
to override the swift account from the storage url that was returned.
Additionally, it includes enough infrastructure to support some commands
in python-openstackclient&gt;=3.0:

    export OS_AUTH_TYPE=v1password
    export OS_AUTH_URL=http://saio:8080/auth/v1.0
    export OS_PROJECT_NAME=AUTH_test2
    export OS_USERNAME=test:tester
    export OS_PASSWORD=testing

    openstack token issue
    openstack catalog list
    openstack catalog show object-store
    openstack object store account show
    openstack container list
    openstack container create &lt;container&gt;
    openstack container save &lt;container&gt;
    openstack container show &lt;container&gt;
    openstack container delete &lt;container&gt;
    openstack object list &lt;container&gt;
    openstack object create &lt;container&gt; &lt;file&gt;
    openstack object save &lt;container&gt; &lt;object&gt;
    opsentack object show &lt;container&gt; &lt;object&gt;
    openstack object delete &lt;container&gt; &lt;object&gt;

Change-Id: Ia963dc44415f72a6518227e86d9528a987e07491
</pre>
</div>
</content>
</entry>
</feed>
