Deploy API Manager or OAuth in Docker containers
3 minute read
These steps are optional and only for users who wish to use API Manager or OAuth in a containerized environment.
Deploy API Manager
To deploy API Manager in a Docker container, follow these steps.
Configure API Manager in Policy Studio
Follow these steps:
-
Open Policy Studio and open or create a new project.
-
Select File > Configure API Manager.
-
If you do not have any Cassandra hosts configured, you must add a Cassandra host before you can continue:
- Enter a name for the Cassandra server (for example,
container_cassandra
). - Enter the name of the Cassandra container as the host name (for example,
cassandra228
). - Enter the port of the Cassandra container (for example,
9042
).
- Enter a name for the Cassandra server (for example,
-
Click Next.
-
Enter the appropriate API Manager settings. For full details, see Enable API Manager.
Note
The default API administrator user name and password set in Policy Studio are used only when creating the administrator account in Apache Cassandra. After the account has been created in Cassandra, you cannot change the credentials in Policy Studio. You must use API Manager to change the administrator credentials. You can also reset the administrator password by running thesetup-apimanager
script with the option--resetPassword
inside the Admin Node Manager container. For details, see Reset the default API administrator password. -
Click Finish.
-
Configure additional API Manager settings under Server Settings > API Manager. For example, you can specify custom policies that are called as traffic passes through API Manager.
-
Select File > Export and select a package to export the configuration as a package (
fed
,pol
, orenv
).
Deploy API Manager enabled API Gateway container
Follow the steps in Create and start API Gateway Docker container. When creating the API Gateway Docker image using build_gw_image.py
, specify the deployment package you exported from Policy Studio. For an example, see Create an API Manager or OAuth enabled API Gateway image.
Deploy OAuth services
To deploy OAuth services in a Docker container, follow these steps.
Configure OAuth in Policy Studio
Follow these steps:
- Open Policy Studio and open or create a new project.
- Select File > Configure OAuth.
- If you do not have any Cassandra hosts configured, you must add a Cassandra host before you can continue:
- Enter a name for the Cassandra server (for example,
container_cassandra
). - Enter the name of the Cassandra container as the host name (for example,
cassandra228
). - Enter the port of the Cassandra container (for example,
9042
).
- Enter a name for the Cassandra server (for example,
- Click Next.
- Select the OAuth deployment type. For full details, see Deploy OAuth configuration.
- Click Finish.
- Select File > Export and select a package to export the configuration as a package (
fed
,pol
, orenv
).
Deploy OAuth-enabled API Gateway container
Follow the steps in in Create and start API Gateway Docker container. When creating the API Gateway Docker image using build_gw_image.py
, specify the deployment package you exported from Policy Studio. For an example, see Create an API Manager or OAuth enabled API Gateway image.