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: app-dev/devops-and-containers/devops/oci-devops-terraform-function-java-graalvm/README.md
+15-16Lines changed: 15 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -54,22 +54,21 @@ Clone this repo locally. In OCI Console click <code>Create Stack</code> under <c
54
54
<p>
55
55
OCI DevOps IAM Policies are not part of the stack, please refer to <ahref="https://docs.oracle.com/en-us/iaas/Content/devops/using/devops_iampolicies.htm">docs</a> how to create them first.
56
56
<p>
57
-
Important! Before running the stack it is manadatory to create the OCI Registry repository for the OCI Function container and upload a dummy X86 architecture container to it. The <b>name</b> of the OCIR repo needs to match to the <code>image_name</code> of the Stack variables e.g. <b>helloworldai-java</b>. The image tag must be '<b>1</b>'.
58
-
<br>
59
-
The reason for this is that the Stack cannot create the Function without pointing to an image in OCIR.
60
-
<p>
61
-
This can be done by doing the following in OCI Cloud Shell (assuming the image name is 'helloworldai-java'):
Unless doing this the Stack will run into an error:
69
-
<pre>
70
-
Error: 400-InvalidParameter, Invalid Image fra.ocir.io/<YOUR_TENANCY_NAMESPACE>/<image_name>:1 does not exist or you do not have access to use it
71
-
</pre>
72
-
After doing this the Stack can be run to create the OCI DevOps project. After the project creation the build pipelines can be run to build and deploy the OCI Function with real Function code like <ahref="https://github.com/oracle-devrel/technology-engineering/blob/main/app-dev/devops-and-containers/functions/java-helloworld-AI-with-local-dev-and-oci-functions/README.md">this one</a> (the dummy hello-world image won't run properly).
57
+
58
+
### Stack settings
59
+
60
+
Before applying the Stack fill in the vars:
61
+
62
+

63
+
64
+
<ul>
65
+
<li><i>initial_image</i> that is used to create the OCI Function as target environment for the OCI DevOps deployment pipeline.
66
+
By default it is loaded from Dockerhub, but you can use any X86 arch image if want to replace this</li>
67
+
<li><i>docker_user</i> is your OCIR Docker user to push the initial image (above) to OCIR repo for the Function. Replace <namespace> with your <code>tenancy namespace</code>. <code>oracleidentitycloudservice</code> is only used for federated domains/users, not local</li>
68
+
<li><i>docker_password</i> is our OCIR Docker user password (your user profile auth token in OCI)</li>
69
+
</ul>
70
+
71
+
Run Stacks's Apply to create the OCI DevOps project.
73
72
<p>
74
73
The Stack creates only a <i>private subnet</i> in the VCN and hence the Function cannot be called outside the tenancy by default after the build and deploy.
description="Name of the OCI DevOps project and related resources"
7
7
}
8
8
variableimage_name {
9
-
default="helloworldai-java"
10
-
description="Name of the Docker image in OCIR. Important! Create/Push this into the OCIR repo for this before running this Stack, otherwise the stack will fail due to empty image in the function definition You can do this in OCI Cloud Shell using hello-world image from Docker Hub and then tagging and pushing it accordingly."
9
+
default="helloworldai"
10
+
description="Name of the image that is built by the pipelines and deployed in the target OCI Function"
11
+
}
12
+
variabledocker_user {
13
+
description="Your docker user to login OCIR to create the initial Function image"
14
+
}
15
+
variabledocker_pwd {
16
+
description="Your docker password (auth token) to login OCIR to create the initial Function image"
0 commit comments