Skip to content

Commit c31b0ca

Browse files
authored
Merge pull request #57202 from apinnick/gh52120-remove-discrete-tags
GH52120: Replace discrete tags with anchor IDs
2 parents 9cea8a6 + a82c0b1 commit c31b0ca

File tree

1 file changed

+10
-11
lines changed

1 file changed

+10
-11
lines changed

modules/images-create-guide-openshift.adoc

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,19 @@
77
The following are guidelines that apply when creating container images specifically
88
for use on {product-title}.
99
ifdef::openshift-online[]
10-
[discrete]
10+
11+
[id="privileges-and-volume-builds_{context}"]
1112
== Privileges and volume builds
1213

1314
Container images cannot be built using the `VOLUME` directive in the `DOCKERFILE`. Images using a read/write file system must use persistent volumes or `emptyDir` volumes instead of local storage. Instead of specifying a volume in the Dockerfile, specify a directory for local storage and mount either a persistent volume or `emptyDir` volume to that directory when deploying the pod.
1415
endif::[]
1516

16-
[discrete]
17+
[id="enable-images-for-source-to-image_{context}"]
1718
== Enable images for source-to-image (S2I)
1819

1920
For images that are intended to run application code provided by a third party, such as a Ruby image designed to run Ruby code provided by a developer, you can enable your image to work with the link:https://github.com/openshift/source-to-image[Source-to-Image (S2I)] build tool. S2I is a framework that makes it easy to write images that take application source code as an input and produce a new image that runs the assembled application as output.
2021

21-
[discrete]
22+
2223
[id="use-uid_{context}"]
2324
== Support arbitrary user ids
2425

@@ -52,7 +53,6 @@ If your S2I image does not include a `USER` declaration with a numeric user, you
5253
====
5354
endif::[]
5455

55-
[discrete]
5656
[id="use-services_{context}"]
5757
== Use services for inter-image communication
5858

@@ -62,12 +62,11 @@ For cases where your image needs to communicate with a service provided by anoth
6262
For more information see https://kubernetes.io/docs/concepts/services-networking/service/[this documentation]. (NOTE to docs team: this link should really go to something in the openshift docs once we have it)
6363
////
6464

65-
[discrete]
65+
[id="provide-common-libraries_{context}"]
6666
== Provide common libraries
6767

6868
For images that are intended to run application code provided by a third party, ensure that your image contains commonly used libraries for your platform. In particular, provide database drivers for common databases used with your platform. For example, provide JDBC drivers for MySQL and PostgreSQL if you are creating a Java framework image. Doing so prevents the need for common dependencies to be downloaded during application assembly time, speeding up application image builds. It also simplifies the work required by application developers to ensure all of their dependencies are met.
6969

70-
[discrete]
7170
[id="use-env-vars_{context}"]
7271
== Use environment variables for configuration
7372

@@ -92,31 +91,31 @@ in containers:
9291
- Blog article - http://fabiokung.com/2014/03/13/memory-inside-linux-containers[Memory inside Linux containers]
9392
////
9493

95-
[discrete]
94+
[id="set-image-metadata_{context}"]
9695
== Set image metadata
9796

9897
Defining image metadata helps {product-title} better consume your container images, allowing {product-title} to create a better experience for developers using your image. For example, you can add metadata to provide helpful descriptions of your image, or offer suggestions on other images that are needed.
9998

100-
[discrete]
99+
[id="clustering_{context}"]
101100
== Clustering
102101

103102
You must fully understand what it means to run multiple instances of your image. In the simplest case, the load balancing function of a service handles routing traffic to all instances of your image. However, many frameworks must share information to perform leader election or failover state; for example, in session replication.
104103

105104
Consider how your instances accomplish this communication when running in {product-title}. Although pods can communicate directly with each other, their IP addresses change anytime the pod starts, stops, or is moved. Therefore, it is important for your clustering scheme to be dynamic.
106105

107-
[discrete]
106+
[id="logging_{context}"]
108107
== Logging
109108

110109
It is best to send all logging to standard out. {product-title} collects standard out from containers and sends it to the centralized logging service where it can be viewed. If you must separate log content, prefix the output with an appropriate keyword, which makes it possible to filter the messages.
111110

112111
If your image logs to a file, users must use manual operations to enter the running container and retrieve or view the log file.
113112

114-
[discrete]
113+
[id="liveness-and-readiness-probes_{context}"]
115114
== Liveness and readiness probes
116115

117116
Document example liveness and readiness probes that can be used with your image. These probes allow users to deploy your image with confidence that traffic is not be routed to the container until it is prepared to handle it, and that the container is restarted if the process gets into an unhealthy state.
118117

119-
[discrete]
118+
[id="templates_{context}"]
120119
== Templates
121120

122121
Consider providing an example template with your image. A template gives users an easy way to quickly get your image deployed with a working configuration. Your template must include the liveness and readiness probes you documented with the image, for completeness.

0 commit comments

Comments
 (0)