You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: samples/oci-apigw-idcs-auth-basic/README.md
+16-16Lines changed: 16 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,8 @@
1
-
# API Gateway Basicauth function using IDCS
1
+
# API Gateway Basicauth function using Identity Cloud Service (IDCS)
2
2
3
3
This function provides verification of username and password against IDCS at runtime and allows only authorized users to access API gateway deployment.
4
4
5
-
The implementation conforms to the guidelines in the OCI Documentation at https://docs.cloud.oracle.com/en-us/iaas/Content/APIGateway/Tasks/apigatewayusingauthorizerfunction.htm.
5
+
The implementation conforms to the [documented guidlines for using authorizer functions to add Authentication and Authorization to API deployments](https://docs.cloud.oracle.com/en-us/iaas/Content/APIGateway/Tasks/apigatewayusingauthorizerfunction.htm).
6
6
7
7
As you make your way through this tutorial, look out for this icon .
8
8
Whenever you see it, it's time for you to perform an action.
@@ -11,7 +11,7 @@ Whenever you see it, it's time for you to perform an action.
11
11
12
12
[Create users in IDCS](https://docs.oracle.com/en/cloud/paas/identity-cloud/uaids/create-user-accounts.html)
13
13
14
-
Before you deploy this sample function, make sure you have run step A, B and C of the [Oracle Functions Quick Start Guide for Cloud Shell](https://www.oracle.com/webfolder/technetwork/tutorials/infographics/oci_functions_cloudshell_quickview/functions_quickview_top/functions_quickview/index.html)
14
+
Before you deploy this sample function, you need to complete steps A, B and C of the [Oracle Functions Quick Start Guide for Cloud Shell](https://www.oracle.com/webfolder/technetwork/tutorials/infographics/oci_functions_cloudshell_quickview/functions_quickview_top/functions_quickview/index.html)
15
15
16
16
- A - Set up your tenancy
17
17
- B - Create application
@@ -29,8 +29,8 @@ fn ls apps
29
29
## Deploy a function that implements an API
30
30
31
31
We need another function that will be a target for API Gateway. We suggest [oci-display-httprequest-info-python](../oci-display-httprequest-info-python).
32
-
In Cloud Shell, run the _fn deploy_ command to build the function and its dependencies as a Docker image,
33
-
push the image to OCIR, and deploy the function to Oracle Functions in your application.
32
+
In Cloud Shell, run `fn deploy`to build the function and its dependencies as a container,
33
+
push the image to Oracle Cloud Infrastructure Registry (OCIR), and deploy the function to Oracle Functions in your application.
34
34
35
35

36
36
@@ -108,11 +108,11 @@ Note the _IDCS URL_, this is the URL you see in your browser URL bar, copy the I
108
108
109
109
Review the following files in the current folder:
110
110
111
-
-[pom.xml](./pom.xml) specifies all the dependencies for your function
112
-
-[func.yaml](./func.yaml) that contains metadata about your function and declares properties
113
-
-[src/main/java/com/example/fn/BasicAuth.java](./src/main/java/com/example/fn/BasicAuth.java) which contains the Java code
111
+
-[`pom.xml`](./pom.xml) specifies all the dependencies for your function
112
+
-[`func.yaml`](./func.yaml) that contains metadata about your function and declares properties
113
+
-[`src/main/java/com/example/fn/BasicAuth.java`](./src/main/java/com/example/fn/BasicAuth.java) which contains the Java code
114
114
115
-
The name of your function _basicauth_ is specified in [func.yaml](./func.yaml).
115
+
The name of your function `basicauth` is specified in [`func.yaml`](./func.yaml).
116
116
117
117
set the following config variables to the values noted while configuring IDCS. The IDCS URL is the token endpoint that returns the access token after validating credentials
@@ -137,22 +137,22 @@ For the unit test to run, set the following variables in src/test/java/com/examp
137
137
138
138
## Deploy the basicauth function
139
139
140
-
In Cloud Shell, run the _fn deploy_ command to build the function and its dependencies as a Docker image,
140
+
In Cloud Shell, run `fn deploy`to build the function and its dependencies as a container,
141
141
push the image to OCIR, and deploy the function to Oracle Functions in your application.
142
142
143
143

144
144
145
-
```
145
+
```shell
146
146
fn -v deploy --app <app-name>
147
147
```
148
148
149
149
## Invoke the basicauth function in cloud shell
150
150
151
-
In Cloud Shell, run _fn invoke_ command to invoke the deployed function, returns active status as true if the token is valid or else returns false.
151
+
In Cloud Shell, run `fn invoke`to invoke the deployed function. It should return an active status of true if the token is valid or otherwise returns false.
0 commit comments