Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
688bb3e
fix index links
k0ka Jan 17, 2024
ebf3ad6
check adding index to toc
k0ka Jan 17, 2024
179be75
check adding index to toc
k0ka Jan 17, 2024
ef5df8a
playing with toc
k0ka Jan 17, 2024
807a13b
add OpenStack creation
k0ka Jan 17, 2024
23d1685
add OpenStack creation
k0ka Jan 17, 2024
692b514
fix OpenStack creation
k0ka Jan 17, 2024
ef887d4
fix OpenStack creation
k0ka Jan 17, 2024
09c629f
fix OpenStack creation
k0ka Jan 17, 2024
7cc793c
doc fixes
k0ka Jan 17, 2024
70f27c3
add collapsible auth code
k0ka Jan 17, 2024
dc8d9d6
add collapsible auth code
k0ka Jan 17, 2024
34b838e
add collapsible auth code
k0ka Jan 17, 2024
074efe4
add collapsible auth code
k0ka Jan 17, 2024
6e851df
fix styling
k0ka Jan 17, 2024
4773de8
Merge branch 'master' into rewrite-docs
k0ka Jan 17, 2024
b545ad3
typo
k0ka Jan 17, 2024
d23c1e4
add collapsible auth code
k0ka Jan 18, 2024
67a36de
add collapsible auth code
k0ka Jan 18, 2024
3971434
fix docs
k0ka Jan 18, 2024
200360e
fix docs
k0ka Jan 18, 2024
a8da1e0
fix docs
k0ka Jan 18, 2024
8b2f4e6
remove code example
k0ka Jan 18, 2024
e2da944
testing docs
k0ka Jan 18, 2024
51e45c7
testing docs
k0ka Jan 18, 2024
0f00809
testing docs
k0ka Jan 18, 2024
4287776
testing docs
k0ka Jan 18, 2024
8e9c1b5
testing docs
k0ka Jan 18, 2024
b12a1a0
show authentication samples
k0ka Jan 18, 2024
9cabf4c
fix link
k0ka Jan 18, 2024
92d48d2
credentials doc
k0ka Jan 18, 2024
ee326c7
- add osdoc
k0ka Jan 18, 2024
a313d7c
fix osdoc
k0ka Jan 18, 2024
9cc4929
check include
k0ka Jan 18, 2024
404f581
added service.rst
k0ka Jan 18, 2024
933bf4b
fix documentation for identity v2 and v3
k0ka Jan 19, 2024
a3d2792
clarify auth docs
k0ka Jan 19, 2024
3572575
fix samples
k0ka Jan 19, 2024
090571a
- Block Storage
k0ka Jan 19, 2024
d349536
fix sample name
k0ka Jan 19, 2024
fdfd5b6
fix compute v2
k0ka Jan 19, 2024
a14ea62
Apply php-cs-fixer changes
k0ka Jan 19, 2024
d22523e
images service doc
k0ka Jan 19, 2024
fa2bcd9
unify create-service docs
k0ka Jan 20, 2024
7af31ed
upgrade object store docs
k0ka Jan 21, 2024
52df2be
Merge branch 'master' into rewrite-docs
k0ka Jan 27, 2024
8eba760
new docs for networking
k0ka Jan 30, 2024
e4fe49c
final fixes
k0ka Jan 30, 2024
6b4feae
run tests
k0ka Jan 30, 2024
c8b197e
fix test
k0ka Jan 30, 2024
2a0446c
fix test
k0ka Jan 30, 2024
82d75b5
fix tests
k0ka Jan 30, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add OpenStack creation
  • Loading branch information
k0ka committed Jan 17, 2024
commit 807a13b0e2d44af97ca8befa104384a261de59aa
41 changes: 41 additions & 0 deletions doc/quick-start.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ You must install this library through Composer:

If you do not have Composer installed, please read the `Composer installation instructions`_.

Include the autoloader
----------------------

Once you have installed the SDK as a dependency of your project, you will need to load Composer’s autoloader
(which registers all the required namespaces). To do this, place the following line of PHP code at the top of your
application’s PHP files:
Expand All @@ -29,4 +32,42 @@ application’s PHP files:
This assumes your application's PHP files are located in the same folder as ``vendor/``. If your files are located
elsewhere, please supply the path to vendor/autoload.php in the require statement above.

Creating a client
-----------------

To create a client, you will need to provide the following information:
* The identity service URL (``authUrl``)
* The region in which you want to operate (``region``)
* The credentials of the user you want to authenticate (``user``), (``tokenId``), (``cachedToken``)
or (``application_credential``)

Only the ``authUrl`` is mandatory to create a client. But you will have to provide the ``region`` and ``user``
to each service you create. So it is recommended to provide them when creating the client.

There are different ways to provide the authentication credentials. See the `Token generation`_ section for
the full list of options. Here is an example of how to create a client with a user id and password:

.. code-block:: php
$openstack = new OpenStack\OpenStack([
'authUrl' => '{authUrl}',
'region' => '{region}',
'user' => [
'id' => '{userId}',
'password' => '{password}'
],
]);

Here is an example of how to create a client with application credentials:

.. code-block:: php
$openstack = new OpenStack\OpenStack([
'authUrl' => '{authUrl}',
'region' => '{region}',
'application_credential' => [
'id' => '{applicationCredentialId}',
'secret' => '{secret}'
]
]);

.. _Composer installation instructions: https://getcomposer.org/doc/00-intro.md
.. _Token generation: /services/identity/v3/tokens
14 changes: 14 additions & 0 deletions doc/services/identity/v3/index.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,20 @@
Identity v3
===========

Creating the service
--------------------

Service can be created via `identityV3` method of `OpenStack` object:
.. code-block:: php
$service = $openstack->identityV3();

A list of additional options can be passed to the method. For example, to change the region:
.. code-block:: php
$service = $openstack->identityV3(['region' => '{region}']);

Service methods
---------------

.. toctree::
:maxdepth: 3

Expand Down