|
62 | 62 | } |
63 | 63 | ] |
64 | 64 | }, |
65 | | - "container": { |
| 65 | + "jobContainer": { |
66 | 66 | "type": "object", |
67 | 67 | "properties": { |
68 | 68 | "image": { |
69 | | - "$comment": "https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions#jobsjob_idcontainerimage", |
| 69 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idcontainerimage", |
70 | 70 | "description": "The Docker image to use as the container to run the action. The value can be the Docker Hub image name or a registry name.", |
71 | 71 | "type": "string" |
72 | 72 | }, |
73 | 73 | "credentials": { |
74 | | - "$comment": "https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions#jobsjob_idcontainercredentials", |
| 74 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idcontainercredentials", |
75 | 75 | "description": "If the image's container registry requires authentication to pull the image, you can use credentials to set a map of the username and password. The credentials are the same values that you would provide to the `docker login` command.", |
76 | 76 | "type": "object", |
77 | 77 | "properties": { |
|
84 | 84 | } |
85 | 85 | }, |
86 | 86 | "env": { |
87 | | - "$comment": "https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions#jobsjob_idcontainerenv", |
| 87 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idcontainerenv", |
88 | 88 | "$ref": "#/definitions/env", |
89 | | - "description": "Sets an array of environment variables in the container." |
| 89 | + "description": "Sets a map of environment variables in the container." |
90 | 90 | }, |
91 | 91 | "ports": { |
92 | | - "$comment": "https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions#jobsjob_idcontainerports", |
| 92 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idcontainerports", |
93 | 93 | "description": "Sets an array of ports to expose on the container.", |
94 | 94 | "type": "array", |
95 | 95 | "items": { |
|
105 | 105 | "minItems": 1 |
106 | 106 | }, |
107 | 107 | "volumes": { |
108 | | - "$comment": "https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions#jobsjob_idcontainervolumes", |
| 108 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idcontainervolumes", |
109 | 109 | "description": "Sets an array of volumes for the container to use. You can use volumes to share data between services or other steps in a job. You can specify named Docker volumes, anonymous Docker volumes, or bind mounts on the host.\nTo specify a volume, you specify the source and destination path: <source>:<destinationPath>\nThe <source> is a volume name or an absolute path on the host machine, and <destinationPath> is an absolute path in the container.", |
110 | 110 | "type": "array", |
111 | 111 | "items": { |
|
114 | 114 | "minItems": 1 |
115 | 115 | }, |
116 | 116 | "options": { |
117 | | - "$comment": "https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions#jobsjob_idcontaineroptions", |
| 117 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idcontaineroptions", |
118 | 118 | "description": "Additional Docker container resource options. For a list of options, see https://docs.docker.com/engine/reference/commandline/create/#options.", |
119 | 119 | "type": "string" |
120 | 120 | } |
121 | 121 | }, |
122 | 122 | "required": ["image"], |
123 | 123 | "additionalProperties": false |
124 | 124 | }, |
| 125 | + "serviceContainer": { |
| 126 | + "type": "object", |
| 127 | + "properties": { |
| 128 | + "image": { |
| 129 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idimage", |
| 130 | + "description": "The Docker image to use as the service container to run the action. The value can be the Docker Hub image name or a registry name.", |
| 131 | + "type": "string" |
| 132 | + }, |
| 133 | + "credentials": { |
| 134 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idcredentials", |
| 135 | + "description": "If the image's container registry requires authentication to pull the image, you can use credentials to set a map of the username and password. The credentials are the same values that you would provide to the `docker login` command.", |
| 136 | + "type": "object", |
| 137 | + "properties": { |
| 138 | + "username": { |
| 139 | + "type": "string" |
| 140 | + }, |
| 141 | + "password": { |
| 142 | + "type": "string" |
| 143 | + } |
| 144 | + } |
| 145 | + }, |
| 146 | + "env": { |
| 147 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idenv", |
| 148 | + "$ref": "#/definitions/env", |
| 149 | + "description": "Sets a map of environment variables in the service container." |
| 150 | + }, |
| 151 | + "ports": { |
| 152 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idports", |
| 153 | + "description": "Sets an array of ports to expose on the service container.", |
| 154 | + "type": "array", |
| 155 | + "items": { |
| 156 | + "oneOf": [ |
| 157 | + { |
| 158 | + "type": "number" |
| 159 | + }, |
| 160 | + { |
| 161 | + "type": "string" |
| 162 | + } |
| 163 | + ] |
| 164 | + }, |
| 165 | + "minItems": 1 |
| 166 | + }, |
| 167 | + "volumes": { |
| 168 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idvolumes", |
| 169 | + "description": "Sets an array of volumes for the service container to use. You can use volumes to share data between services or other steps in a job. You can specify named Docker volumes, anonymous Docker volumes, or bind mounts on the host.\nTo specify a volume, you specify the source and destination path: <source>:<destinationPath>\nThe <source> is a volume name or an absolute path on the host machine, and <destinationPath> is an absolute path in the container.", |
| 170 | + "type": "array", |
| 171 | + "items": { |
| 172 | + "type": "string" |
| 173 | + }, |
| 174 | + "minItems": 1 |
| 175 | + }, |
| 176 | + "options": { |
| 177 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idoptions", |
| 178 | + "description": "Additional Docker container resource options. For a list of options, see https://docs.docker.com/engine/reference/commandline/create/#options.", |
| 179 | + "type": "string" |
| 180 | + }, |
| 181 | + "command": { |
| 182 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_idcommand", |
| 183 | + "description": "Overrides the Docker image's default command (`CMD`). The value is passed as arguments after the image name in the `docker create` command. If you also specify `entrypoint`, `command` provides the arguments to that entrypoint.", |
| 184 | + "type": "string" |
| 185 | + }, |
| 186 | + "entrypoint": { |
| 187 | + "$comment": "https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idservicesservice_identrypoint", |
| 188 | + "description": "Overrides the Docker image's default `ENTRYPOINT`. The value is a single string defining the executable to run. Use this when you need to replace the image's entrypoint entirely. You can combine `entrypoint` with `command` to pass arguments to the custom entrypoint.", |
| 189 | + "type": "string" |
| 190 | + } |
| 191 | + }, |
| 192 | + "required": ["image"], |
| 193 | + "additionalProperties": false |
| 194 | + }, |
125 | 195 | "defaults": { |
126 | 196 | "type": "object", |
127 | 197 | "properties": { |
|
829 | 899 | "type": "string" |
830 | 900 | }, |
831 | 901 | { |
832 | | - "$ref": "#/definitions/container" |
| 902 | + "$ref": "#/definitions/jobContainer" |
833 | 903 | } |
834 | 904 | ] |
835 | 905 | }, |
|
838 | 908 | "description": "Additional containers to host services for a job in a workflow. These are useful for creating databases or cache services like redis. The runner on the virtual machine will automatically create a network and manage the life cycle of the service containers.\nWhen you use a service container for a job or your step uses container actions, you don't need to set port information to access the service. Docker automatically exposes all ports between containers on the same network.\nWhen both the job and the action run in a container, you can directly reference the container by its hostname. The hostname is automatically mapped to the service name.\nWhen a step does not use a container action, you must access the service using localhost and bind the ports.", |
839 | 909 | "type": "object", |
840 | 910 | "additionalProperties": { |
841 | | - "$ref": "#/definitions/container" |
| 911 | + "$ref": "#/definitions/serviceContainer" |
842 | 912 | } |
843 | 913 | }, |
844 | 914 | "concurrency": { |
|
0 commit comments