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/functions/java-helloworld-with-local-dev-and-oci-functions/README.md
+50-2Lines changed: 50 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -46,7 +46,7 @@ SOFTWARE.
46
46
47
47
This is an example how I'm locally developing and testing OCI Functions on my mac with Apple silicon that uses mainly ARM architecture and then building and deploying the same to Functions in OCI.
48
48
49
-
<p>
49
+
### Local Dev
50
50
51
51
I've installed maven and <code>Fn cli</code> on my mac. This is how to do the <ahref="https://docs.oracle.com/en-us/iaas/Content/Functions/Tasks/functionsinstallfncli.htm">Fn cli install</a> or like in here <ahref="https://fnproject.io/tutorials/install/">following the Fn tutorial</a>.
Now that the function is properly working locally let's build and deploy it to OCI.
104
104
@@ -108,4 +108,52 @@ First create a OCIR repo for the container in your OCI tenancy <code>compartment
108
108
109
109
<p>
110
110
111
+
Next, let's build the Docker container for the function using <code>docker build</code>, let's not use Fn this time (that is also possible), using the FRA region:
The last step is to create the Function Application and the function deployment for it. This can be easily done using the Cloud UI.
133
+
134
+
<p>
135
+
136
+
To create a mac binary compatible Function Application use the <code>shape GENERIC_ARM</code>. Let's name this <code>hello-arm</code>.
137
+
138
+
<p>
139
+
140
+
Create the Function from the container image that was pushed to the OCIR repo e.g. <code>fra.ocir.io/<YOUR OCI TENANCY NAMESPACE>/helloworld-java:1</code>. Let's name this <code>helloworld-java-arm</code>.
141
+
142
+
<p>
143
+
144
+
After deployment the Function can be easily tested in Cloud Shell following the Getting Started guide for the Application and giving:
0 commit comments