Skip to content

Commit 746b721

Browse files
author
Ma Shimiao
committed
format specs with 4 spaces indent
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
1 parent 49b0a1f commit 746b721

File tree

8 files changed

+148
-161
lines changed

8 files changed

+148
-161
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ Read more on [How to Write a Git Commit Message][how-to-git-commit] or the Discu
145145
5. Use the imperative mood in the subject line
146146
6. Wrap the body at 72 characters
147147
7. Use the body to explain what and why vs. how
148-
* If there was important/useful/essential conversation or information, copy or include a reference
148+
* If there was important/useful/essential conversation or information, copy or include a reference
149149
8. When possible, one keyword to scope the change in the subject (i.e. "README: ...", "runtime: ...")
150150

151151

RELEASES.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,9 @@ Specifications have a variety of different timelines in their lifecycle.
4343

4444
* Pre-v1.0.0 specifications SHOULD release on a monthly cadence to garner feedback.
4545
* Major specification releases MUST release at least three release candidates spaced a minimum of one week apart.
46-
This means a major release like a v1.0.0 or v2.0.0 release will take 1 month at minimum: one week for rc1, one week for rc2, one week for rc3, and one week for the major release itself.
47-
Maintainers SHOULD strive to make zero breaking changes during this cycle of release candidates and SHOULD restart the three-candidate count when a breaking change is introduced.
48-
For example if a breaking change is introduced in v1.0.0-rc2 then the series would end with v1.0.0-rc4 and v1.0.0.
46+
This means a major release like a v1.0.0 or v2.0.0 release will take 1 month at minimum: one week for rc1, one week for rc2, one week for rc3, and one week for the major release itself.
47+
Maintainers SHOULD strive to make zero breaking changes during this cycle of release candidates and SHOULD restart the three-candidate count when a breaking change is introduced.
48+
For example if a breaking change is introduced in v1.0.0-rc2 then the series would end with v1.0.0-rc4 and v1.0.0.
4949
- Minor and patch releases SHOULD be made on an as-needed basis.
5050

5151
[charter]: https://www.opencontainers.org/about/governance

bundle.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@ A Standard Container bundle contains all the information needed to load and run
1111
This includes the following artifacts:
1212

1313
1. <a name="containerFormat01" />`config.json`: contains configuration data.
14-
This REQUIRED file MUST reside in the root of the bundle directory and MUST be named `config.json`.
15-
See [`config.json`](config.md) for more details.
14+
This REQUIRED file MUST reside in the root of the bundle directory and MUST be named `config.json`.
15+
See [`config.json`](config.md) for more details.
1616

1717
2. <a name="containerFormat02" />A directory representing the root filesystem of the container.
18-
On Windows, for Windows Server containers, this directory is REQUIRED. For Hyper-V containers, it MUST be omitted.
18+
On Windows, for Windows Server containers, this directory is REQUIRED.
19+
For Hyper-V containers, it MUST be omitted.
1920

2021
On all other platforms, this field is REQUIRED.
2122

config-linux.md

Lines changed: 46 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -115,12 +115,12 @@ The runtime may supply them however it likes (with [mknod][mknod.2], by bind mou
115115
Each entry has the following structure:
116116

117117
* **`type`** *(string, REQUIRED)* - type of device: `c`, `b`, `u` or `p`.
118-
More info in [mknod(1)][mknod.1].
118+
More info in [mknod(1)][mknod.1].
119119
* **`path`** *(string, REQUIRED)* - full path to device inside container.
120-
If a [file][] already exists at `path` that does not match the requested device, the runtime MUST generate an error.
120+
If a [file][] already exists at `path` that does not match the requested device, the runtime MUST generate an error.
121121
* **`major, minor`** *(int64, REQUIRED unless `type` is `p`)* - [major, minor numbers][devices] for the device.
122122
* **`fileMode`** *(uint32, OPTIONAL)* - file mode for the device.
123-
You can also control access to devices [with cgroups](#device-whitelist).
123+
You can also control access to devices [with cgroups](#device-whitelist).
124124
* **`uid`** *(uint32, OPTIONAL)* - id of device owner.
125125
* **`gid`** *(uint32, OPTIONAL)* - id of device group.
126126

@@ -129,7 +129,7 @@ The same `type`, `major` and `minor` SHOULD NOT be used for multiple devices.
129129
### Example
130130

131131
```json
132-
"devices": [
132+
"devices": [
133133
{
134134
"path": "/dev/fuse",
135135
"type": "c",
@@ -194,18 +194,18 @@ Runtimes MAY attach the container process to additional cgroup controllers beyon
194194
### Example
195195

196196
```json
197-
"cgroupsPath": "/myRuntime/myContainer",
198-
"resources": {
199-
"memory": {
200-
"limit": 100000,
201-
"reservation": 200000
202-
},
203-
"devices": [
204-
{
205-
"allow": false,
206-
"access": "rwm"
207-
}
208-
]
197+
"cgroupsPath": "/myRuntime/myContainer",
198+
"resources": {
199+
"memory": {
200+
"limit": 100000,
201+
"reservation": 200000
202+
},
203+
"devices": [
204+
{
205+
"allow": false,
206+
"access": "rwm"
207+
}
208+
]
209209
}
210210
```
211211

@@ -218,16 +218,16 @@ Each entry has the following structure:
218218

219219
* **`allow`** *(boolean, REQUIRED)* - whether the entry is allowed or denied.
220220
* **`type`** *(string, OPTIONAL)* - type of device: `a` (all), `c` (char), or `b` (block).
221-
Unset values mean "all", mapping to `a`.
221+
Unset values mean "all", mapping to `a`.
222222
* **`major, minor`** *(int64, OPTIONAL)* - [major, minor numbers][devices] for the device.
223-
Unset values mean "all", mapping to [`*` in the filesystem API][cgroup-v1-devices].
223+
Unset values mean "all", mapping to [`*` in the filesystem API][cgroup-v1-devices].
224224
* **`access`** *(string, OPTIONAL)* - cgroup permissions for device.
225-
A composition of `r` (read), `w` (write), and `m` (mknod).
225+
A composition of `r` (read), `w` (write), and `m` (mknod).
226226

227227
#### Example
228228

229229
```json
230-
"devices": [
230+
"devices": [
231231
{
232232
"allow": false,
233233
"access": "rwm"
@@ -273,15 +273,10 @@ For more information, see the kernel cgroups documentation about [memory][cgroup
273273
The following parameters can be specified to set up the controller:
274274

275275
* **`limit`** *(uint64, OPTIONAL)* - sets limit of memory usage in bytes
276-
277276
* **`reservation`** *(uint64, OPTIONAL)* - sets soft limit of memory usage in bytes
278-
279277
* **`swap`** *(uint64, OPTIONAL)* - sets limit of memory+Swap usage
280-
281278
* **`kernel`** *(uint64, OPTIONAL)* - sets hard limit for kernel memory
282-
283279
* **`kernelTCP`** *(uint64, OPTIONAL)* - sets hard limit in bytes for kernel TCP buffer memory
284-
285280
* **`swappiness`** *(uint64, OPTIONAL)* - sets swappiness parameter of vmscan (See sysctl's vm.swappiness)
286281

287282
#### Example
@@ -305,17 +300,11 @@ For more information, see the kernel cgroups documentation about [cpusets][cgrou
305300
The following parameters can be specified to set up the controller:
306301

307302
* **`shares`** *(uint64, OPTIONAL)* - specifies a relative share of CPU time available to the tasks in a cgroup
308-
309303
* **`quota`** *(int64, OPTIONAL)* - specifies the total amount of time in microseconds for which all tasks in a cgroup can run during one period (as defined by **`period`** below)
310-
311304
* **`period`** *(uint64, OPTIONAL)* - specifies a period of time in microseconds for how regularly a cgroup's access to CPU resources should be reallocated (CFS scheduler only)
312-
313305
* **`realtimeRuntime`** *(int64, OPTIONAL)* - specifies a period of time in microseconds for the longest continuous period in which the tasks in a cgroup have access to CPU resources
314-
315306
* **`realtimePeriod`** *(uint64, OPTIONAL)* - same as **`period`** but applies to realtime scheduler only
316-
317307
* **`cpus`** *(string, OPTIONAL)* - list of CPUs the container will run in
318-
319308
* **`mems`** *(string, OPTIONAL)* - list of Memory Nodes the container will run in
320309

321310
#### Example
@@ -340,9 +329,7 @@ For more information, see the kernel cgroups documentation about [blkio][cgroup-
340329
The following parameters can be specified to set up the controller:
341330

342331
* **`blkioWeight`** *(uint16, OPTIONAL)* - specifies per-cgroup weight. This is default weight of the group on all devices until and unless overridden by per-device rules.
343-
344332
* **`blkioLeafWeight`** *(uint16, OPTIONAL)* - equivalents of `blkioWeight` for the purpose of deciding how much weight tasks in the given cgroup has while competing with the cgroup's child cgroups.
345-
346333
* **`blkioWeightDevice`** *(array of objects, OPTIONAL)* - specifies the list of devices which will be bandwidth rate limited. The following parameters can be specified per-device:
347334
* **`major, minor`** *(int64, REQUIRED)* - major, minor numbers for device. More info in [mknod(1)][mknod.1] man page.
348335
* **`weight`** *(uint16, OPTIONAL)* - bandwidth rate for the device.
@@ -351,7 +338,7 @@ The following parameters can be specified to set up the controller:
351338
You MUST specify at least one of `weight` or `leafWeight` in a given entry, and MAY specify both.
352339

353340
* **`blkioThrottleReadBpsDevice`**, **`blkioThrottleWriteBpsDevice`**, **`blkioThrottleReadIOPSDevice`**, **`blkioThrottleWriteIOPSDevice`** *(array of objects, OPTIONAL)* - specify the list of devices which will be IO rate limited.
354-
The following parameters can be specified per-device:
341+
The following parameters can be specified per-device:
355342
* **`major, minor`** *(int64, REQUIRED)* - major, minor numbers for device. More info in [mknod(1)][mknod.1] man page.
356343
* **`rate`** *(uint64, REQUIRED)* - IO rate limit for the device
357344

@@ -400,13 +387,12 @@ For more information, see the kernel cgroups documentation about [HugeTLB][cgrou
400387
Each entry has the following structure:
401388

402389
* **`pageSize`** *(string, REQUIRED)* - hugepage size
403-
404390
* **`limit`** *(uint64, REQUIRED)* - limit in bytes of *hugepagesize* HugeTLB usage
405391

406392
#### Example
407393

408394
```json
409-
"hugepageLimits": [
395+
"hugepageLimits": [
410396
{
411397
"pageSize": "2MB",
412398
"limit": 209715200
@@ -422,16 +408,15 @@ For more information, see the kernel cgroups documentations about [net\_cls cgro
422408
The following parameters can be specified to set up the controller:
423409

424410
* **`classID`** *(uint32, OPTIONAL)* - is the network class identifier the cgroup's network packets will be tagged with
425-
426411
* **`priorities`** *(array of objects, OPTIONAL)* - specifies a list of objects of the priorities assigned to traffic originating from processes in the group and egressing the system on various interfaces.
427-
The following parameters can be specified per-priority:
412+
The following parameters can be specified per-priority:
428413
* **`name`** *(string, REQUIRED)* - interface name in [runtime network namespace](glossary.md#runtime-namespace)
429414
* **`priority`** *(uint32, REQUIRED)* - priority applied to the interface
430415

431416
#### Example
432417

433418
```json
434-
"network": {
419+
"network": {
435420
"classID": 1048577,
436421
"priorities": [
437422
{
@@ -458,7 +443,7 @@ The following parameters can be specified to set up the controller:
458443
#### Example
459444

460445
```json
461-
"pids": {
446+
"pids": {
462447
"limit": 32771
463448
}
464449
```
@@ -499,7 +484,7 @@ For more information, see the [sysctl(8)][sysctl.8] man page.
499484
### Example
500485

501486
```json
502-
"sysctl": {
487+
"sysctl": {
503488
"net.ipv4.ip_forward": "1",
504489
"net.core.somaxconn": "256"
505490
}
@@ -549,7 +534,6 @@ The following parameters can be specified to set up seccomp:
549534

550535
* **`names`** *(array of strings, REQUIRED)* - the names of the syscalls.
551536
`names` MUST contain at least one entry.
552-
553537
* **`action`** *(string, REQUIRED)* - the action for seccomp rules.
554538
A valid list of constants as of libseccomp v2.3.2 is shown below.
555539

@@ -564,11 +548,8 @@ The following parameters can be specified to set up seccomp:
564548
Each entry has the following structure:
565549

566550
* **`index`** *(uint, REQUIRED)* - the index for syscall arguments in seccomp.
567-
568551
* **`value`** *(uint64, REQUIRED)* - the value for syscall arguments in seccomp.
569-
570552
* **`valueTwo`** *(uint64, REQUIRED)* - the value for syscall arguments in seccomp.
571-
572553
* **`op`** *(string, REQUIRED)* - the operator for syscall arguments in seccomp.
573554
A valid list of constants as of libseccomp v2.3.2 is shown below.
574555

@@ -583,29 +564,29 @@ The following parameters can be specified to set up seccomp:
583564
### Example
584565

585566
```json
586-
"seccomp": {
587-
"defaultAction": "SCMP_ACT_ALLOW",
588-
"architectures": [
589-
"SCMP_ARCH_X86",
590-
"SCMP_ARCH_X32"
591-
],
592-
"syscalls": [
593-
{
594-
"names": [
595-
"getcwd",
596-
"chmod"
597-
],
598-
"action": "SCMP_ACT_ERRNO"
599-
}
600-
]
601-
}
567+
"seccomp": {
568+
"defaultAction": "SCMP_ACT_ALLOW",
569+
"architectures": [
570+
"SCMP_ARCH_X86",
571+
"SCMP_ARCH_X32"
572+
],
573+
"syscalls": [
574+
{
575+
"names": [
576+
"getcwd",
577+
"chmod"
578+
],
579+
"action": "SCMP_ACT_ERRNO"
580+
}
581+
]
582+
}
602583
```
603584

604585
## <a name="configLinuxRootfsMountPropagation" />Rootfs Mount Propagation
605586

606587
**`rootfsPropagation`** (string, OPTIONAL) sets the rootfs's mount propagation.
607-
Its value is either slave, private, shared or unbindable.
608-
The [Shared Subtrees][sharedsubtree] article in the kernel documentation has more information about mount propagation.
588+
Its value is either slave, private, shared or unbindable.
589+
The [Shared Subtrees][sharedsubtree] article in the kernel documentation has more information about mount propagation.
609590

610591
### Example
611592

@@ -616,7 +597,7 @@ The [Shared Subtrees][sharedsubtree] article in the kernel documentation has mor
616597
## <a name="configLinuxMaskedPaths" />Masked Paths
617598

618599
**`maskedPaths`** (array of strings, OPTIONAL) will mask over the provided paths inside the container so that they cannot be read.
619-
The values MUST be absolute paths in the [container namespace](glossary.md#container_namespace).
600+
The values MUST be absolute paths in the [container namespace](glossary.md#container_namespace).
620601

621602
### Example
622603

@@ -629,7 +610,7 @@ The values MUST be absolute paths in the [container namespace](glossary.md#conta
629610
## <a name="configLinuxReadonlyPaths" />Readonly Paths
630611

631612
**`readonlyPaths`** (array of strings, OPTIONAL) will set the provided paths as readonly inside the container.
632-
The values MUST be absolute paths in the [container namespace](glossary.md#container-namespace).
613+
The values MUST be absolute paths in the [container namespace](glossary.md#container-namespace).
633614

634615
### Example
635616

config-solaris.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -83,21 +83,21 @@ For additional information on properties, check the [zonecfg(1M)][zonecfg.1m_2]
8383
* **`linkname`** *(string, OPTIONAL)* Specify a name for the automatically created VNIC datalink.
8484
* **`lowerLink`** *(string, OPTIONAL)* Specify the link over which the VNIC will be created.
8585
Mapped to `lower-link` in the [zonecfg(1M)][zonecfg.1m_2] man page.
86-
* **`allowedAddress`** *(string, OPTIONAL)* The set of IP addresses that the container can use might be constrained by specifying the allowedAddress property.
87-
If allowedAddress has not been specified, then they can use any IP address on the associated physical interface for the network resource.
88-
Otherwise, when allowedAddress is specified, the container cannot use IP addresses that are not in the allowedAddress list for the physical address.
89-
Mapped to `allowed-address` in the [zonecfg(1M)][zonecfg.1m_2] man page.
90-
* **`configureAllowedAddress`** *(string, OPTIONAL)* If configureAllowedAddress is set to true, the addresses specified by allowedAddress are automatically configured on the interface each time the container starts.
91-
When it is set to false, the allowedAddress will not be configured on container start.
92-
Mapped to `configure-allowed-address` in the [zonecfg(1M)][zonecfg.1m_2] man page.
86+
* **`allowedAddress`** *(string, OPTIONAL)* The set of IP addresses that the container can use might be constrained by specifying the `allowedAddress` property.
87+
If `allowedAddress` has not been specified, then they can use any IP address on the associated physical interface for the network resource.
88+
Otherwise, when `allowedAddress` is specified, the container cannot use IP addresses that are not in the `allowedAddress` list for the physical address.
89+
Mapped to `allowed-address` in the [zonecfg(1M)][zonecfg.1m_2] man page.
90+
* **`configureAllowedAddress`** *(string, OPTIONAL)* If `configureAllowedAddress` is set to true, the addresses specified by `allowedAddress` are automatically configured on the interface each time the container starts.
91+
When it is set to false, the `allowedAddress` will not be configured on container start.
92+
Mapped to `configure-allowed-address` in the [zonecfg(1M)][zonecfg.1m_2] man page.
9393
* **`defrouter`** *(string, OPTIONAL)* The value for the OPTIONAL default router.
9494
* **`macAddress`** *(string, OPTIONAL)* Set the VNIC's MAC addresses based on the specified value or keyword.
95-
If not a keyword, it is interpreted as a unicast MAC address.
96-
For a list of the supported keywords please refer to the [zonecfg(1M)][zonecfg.1m_2] man page of the respective Solaris release.
97-
Mapped to `mac-address` in the [zonecfg(1M)][zonecfg.1m_2] man page.
95+
If not a keyword, it is interpreted as a unicast MAC address.
96+
For a list of the supported keywords please refer to the [zonecfg(1M)][zonecfg.1m_2] man page of the respective Solaris release.
97+
Mapped to `mac-address` in the [zonecfg(1M)][zonecfg.1m_2] man page.
9898
* **`linkProtection`** *(string, OPTIONAL)* Enables one or more types of link protection using comma-separated values.
99-
See the protection property in dladm(8) for supported values in respective release of Solaris.
100-
Mapped to `link-protection` in the [zonecfg(1M)][zonecfg.1m_2] man page.
99+
See the protection property in dladm(8) for supported values in respective release of Solaris.
100+
Mapped to `link-protection` in the [zonecfg(1M)][zonecfg.1m_2] man page.
101101

102102
#### Example
103103
```json

config-windows.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,7 @@ The following parameters can be specified:
3434
The following parameters can be specified:
3535

3636
* **`count`** *(uint64, OPTIONAL)* - specifies the number of CPUs available to the container.
37-
3837
* **`shares`** *(uint16, OPTIONAL)* - specifies the relative weight to other containers with CPU shares.
39-
4038
* **`maximum`** *(uint, OPTIONAL)* - specifies the portion of processor cycles that this container can use as a percentage times 100.
4139

4240
#### Example
@@ -58,9 +56,7 @@ The following parameters can be specified:
5856
The following parameters can be specified:
5957

6058
* **`iops`** *(uint64, OPTIONAL)* - specifies the maximum IO operations per second for the system drive of the container.
61-
6259
* **`bps`** *(uint64, OPTIONAL)* - specifies the maximum bytes per second for the system drive of the container.
63-
6460
* **`sandboxSize`** *(uint64, OPTIONAL)* - specifies the minimum size of the system drive in bytes.
6561

6662
#### Example
@@ -142,11 +138,15 @@ You can indicate that a container should be started in an a mode where disk flus
142138

143139
## <a name="configWindowsHyperV" />HyperV
144140

145-
`hyperv` is an OPTIONAL field of the Windows configuration. If present, the container MUST be run with Hyper-V isolation. If omitted, the container MUST be run as a Windows Server container.
141+
`hyperv` is an OPTIONAL field of the Windows configuration.
142+
If present, the container MUST be run with Hyper-V isolation.
143+
If omitted, the container MUST be run as a Windows Server container.
146144

147145
The following parameters can be specified:
148146

149-
* **`utilityvmpath`** *(string, OPTIONAL)* - specifies the path to the image used for the utility VM. This would be specified if using a base image which does not contain a utility VM image. If not supplied, the runtime will search the container filesystem layers from the bottom-most layer upwards, until it locates "UtilityVM", and default to that path.
147+
* **`utilityvmpath`** *(string, OPTIONAL)* - specifies the path to the image used for the utility VM.
148+
This would be specified if using a base image which does not contain a utility VM image.
149+
If not supplied, the runtime will search the container filesystem layers from the bottom-most layer upwards, until it locates "UtilityVM", and default to that path.
150150

151151
* **`sandboxpath`** *(string, REQUIRED)* - specifies the root of the path to the sandbox to be used for the container.
152152

@@ -159,4 +159,4 @@ The following parameters can be specified:
159159
"sandboxpath": "C:\\\\programdata\\\\docker\\\\windowsfilter
160160
}
161161
}
162-
```
162+
```

0 commit comments

Comments
 (0)