mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-06 06:46:26 +01:00
103 lines
2.1 KiB
Plaintext
103 lines
2.1 KiB
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * serverless/serving-creating-managing-apps.adoc
|
|
|
|
[id="verifying-serverless-app-deployment_{context}"]
|
|
= Verifying your serverless application deployment
|
|
|
|
To verify that your serverless application has been deployed successfully, you must get the application URL created by Knative, and then send a request to that URL and observe the output.
|
|
|
|
[NOTE]
|
|
====
|
|
{ServerlessProductName} supports the use of both HTTP and HTTPS URLs, however the output from `oc get ksvc` will always print URLs using the `http://` format.
|
|
====
|
|
|
|
.Procedure
|
|
|
|
. Find the application URL by entering:
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
$ oc get ksvc <service_name>
|
|
----
|
|
|
|
+
|
|
.Example output
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
NAME URL LATESTCREATED LATESTREADY READY REASON
|
|
hello http://hello-default.example.com hello-4wsd2 hello-4wsd2 True
|
|
----
|
|
|
|
. Make a request to your cluster and observe the output.
|
|
+
|
|
.Example HTTP request
|
|
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ curl http://hello-default.example.com
|
|
----
|
|
|
|
+
|
|
.Example HTTPS request
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
$ curl https://hello-default.example.com
|
|
----
|
|
|
|
+
|
|
.Example output
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
Hello Serverless!
|
|
----
|
|
|
|
. Optional. If you receive an error relating to a self-signed certificate in the certificate chain, you can add the `--insecure` flag to the curl command to ignore the error:
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
$ curl https://hello-default.example.com --insecure
|
|
----
|
|
|
|
+
|
|
.Example output
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
Hello Serverless!
|
|
----
|
|
|
|
+
|
|
[IMPORTANT]
|
|
====
|
|
Self-signed certificates must not be used in a production deployment. This method is only for testing purposes.
|
|
====
|
|
|
|
. Optional. If your {product-title} cluster is configured with a certificate that is signed by a certificate authority (CA) but not yet globally configured for your system, you can specify this with the `curl` command.
|
|
The path to the certificate can be passed to the curl command by using the `--cacert` flag:
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
$ curl https://hello-default.example.com --cacert <file>
|
|
----
|
|
|
|
+
|
|
.Example output
|
|
+
|
|
|
|
[source,terminal]
|
|
----
|
|
Hello Serverless!
|
|
----
|