-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
102 additions
and
324 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
allOf: | ||
- $ref: '../BaseResponse.yaml' | ||
- type: object | ||
required: | ||
- environment | ||
- name | ||
- tag | ||
- auto_preview | ||
- cpu | ||
- memory | ||
- min_running_instances | ||
- max_running_instances | ||
- maximum_cpu | ||
- maximum_memory | ||
- healthchecks | ||
- source | ||
properties: | ||
environment: | ||
$ref: '../ReferenceObject.yaml' | ||
maximum_cpu: | ||
type: integer | ||
description: Maximum cpu that can be allocated to the job based on organization cluster configuration. unit is millicores (m). 1000m = 1 cpu | ||
example: 16000 | ||
maximum_memory: | ||
type: integer | ||
description: Maximum memory that can be allocated to the job based on organization cluster configuration. unit is MB. 1024 MB = 1GB | ||
example: 16384 | ||
name: | ||
type: string | ||
description: name is case insensitive | ||
description: | ||
type: string | ||
cpu: | ||
type: integer | ||
description: unit is millicores (m). 1000m = 1 cpu | ||
example: 1250 | ||
memory: | ||
type: integer | ||
description: unit is MB. 1024 MB = 1GB | ||
example: 1024 | ||
max_nb_restart: | ||
type: integer | ||
minimum: 0 | ||
description: | | ||
Maximum number of restart allowed before the job is considered as failed | ||
0 means that no restart/crash of the job is allowed | ||
max_duration_seconds: | ||
type: integer | ||
minimum: 0 | ||
description: | | ||
Maximum number of seconds allowed for the job to run before killing it and mark it as failed | ||
auto_preview: | ||
type: boolean | ||
description: | | ||
Indicates if the 'environment preview option' is enabled for this container. | ||
If enabled, a preview environment will be automatically cloned when `/preview` endpoint is called. | ||
If not specified, it takes the value of the `auto_preview` property from the associated environment. | ||
port: | ||
type: integer | ||
nullable: true | ||
minimum: 1 | ||
description: Port where to run readiness and liveliness probes checks. The port will not be exposed externally | ||
default: null | ||
source: | ||
nullable: false | ||
oneOf: | ||
- type: object | ||
properties: | ||
image: | ||
$ref: '../ContainerSource.yaml' | ||
- type: object | ||
properties: | ||
docker: | ||
type: object | ||
properties: | ||
dockerfile_path: | ||
type: string | ||
description: The path of the associated Dockerfile. Only if you are using build_mode = DOCKER | ||
nullable: true | ||
git_repository: | ||
$ref: '../ApplicationGitRepositoryResponse.yaml' | ||
healthchecks: | ||
$ref: '../Healthcheck.yaml' | ||
auto_deploy: | ||
type: boolean | ||
description: | | ||
Specify if the job will be automatically updated after receiving a new image tag or a new commit according to the source type. | ||
The new image tag shall be communicated via the "Auto Deploy job" endpoint https://api-doc.qovery.com/#tag/Jobs/operation/autoDeployJobEnvironments |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,145 +1,8 @@ | ||
allOf: | ||
- $ref: '../BaseResponse.yaml' | ||
- type: object | ||
required: | ||
- environment | ||
- name | ||
- tag | ||
- auto_preview | ||
- cpu | ||
- memory | ||
- min_running_instances | ||
- max_running_instances | ||
- maximum_cpu | ||
- maximum_memory | ||
- healthchecks | ||
- source | ||
properties: | ||
environment: | ||
$ref: '../ReferenceObject.yaml' | ||
maximum_cpu: | ||
type: integer | ||
description: Maximum cpu that can be allocated to the job based on organization cluster configuration. unit is millicores (m). 1000m = 1 cpu | ||
example: 16000 | ||
maximum_memory: | ||
type: integer | ||
description: Maximum memory that can be allocated to the job based on organization cluster configuration. unit is MB. 1024 MB = 1GB | ||
example: 16384 | ||
name: | ||
type: string | ||
description: name is case insensitive | ||
description: | ||
type: string | ||
cpu: | ||
type: integer | ||
description: unit is millicores (m). 1000m = 1 cpu | ||
example: 1250 | ||
memory: | ||
type: integer | ||
description: unit is MB. 1024 MB = 1GB | ||
example: 1024 | ||
max_nb_restart: | ||
type: integer | ||
minimum: 0 | ||
description: | | ||
Maximum number of restart allowed before the job is considered as failed | ||
0 means that no restart/crash of the job is allowed | ||
max_duration_seconds: | ||
type: integer | ||
minimum: 0 | ||
description: | | ||
Maximum number of seconds allowed for the job to run before killing it and mark it as failed | ||
auto_preview: | ||
type: boolean | ||
description: | | ||
Indicates if the 'environment preview option' is enabled for this container. | ||
If enabled, a preview environment will be automatically cloned when `/preview` endpoint is called. | ||
If not specified, it takes the value of the `auto_preview` property from the associated environment. | ||
port: | ||
type: integer | ||
nullable: true | ||
minimum: 1 | ||
description: Port where to run readiness and liveliness probes checks. The port will not be exposed externally | ||
default: null | ||
source: | ||
nullable: false | ||
oneOf: | ||
- type: object | ||
properties: | ||
image: | ||
$ref: '../ContainerSource.yaml' | ||
- type: object | ||
properties: | ||
docker: | ||
type: object | ||
properties: | ||
dockerfile_path: | ||
type: string | ||
description: The path of the associated Dockerfile. Only if you are using build_mode = DOCKER | ||
nullable: true | ||
git_repository: | ||
$ref: '../ApplicationGitRepositoryResponse.yaml' | ||
healthchecks: | ||
$ref: '../Healthcheck.yaml' | ||
schedule: | ||
type: object | ||
description: | | ||
If you want to define a Cron job, only the `cronjob` property must be filled | ||
A Lifecycle job should contain at least one property `on_XXX` among the 3 properties: `on_start`, `on_stop`, `on_delete` | ||
properties: | ||
on_start: | ||
type: object | ||
properties: | ||
arguments: | ||
type: array | ||
items: | ||
type: string | ||
entrypoint: | ||
type: string | ||
description: optional entrypoint when launching container | ||
on_stop: | ||
type: object | ||
properties: | ||
arguments: | ||
type: array | ||
items: | ||
type: string | ||
entrypoint: | ||
type: string | ||
description: optional entrypoint when launching container | ||
on_delete: | ||
type: object | ||
properties: | ||
arguments: | ||
type: array | ||
items: | ||
type: string | ||
entrypoint: | ||
type: string | ||
description: optional entrypoint when launching container | ||
cronjob: | ||
type: object | ||
required: | ||
- scheduled_at | ||
properties: | ||
arguments: | ||
type: array | ||
items: | ||
type: string | ||
entrypoint: | ||
type: string | ||
description: optional entrypoint when launching container | ||
scheduled_at: | ||
type: string | ||
format: cron | ||
description: | | ||
Can only be set if the event is CRON. | ||
Represent the cron format for the job schedule without seconds. | ||
For example: `* * * * *` represent the cron to launch the job every minute. | ||
See https://crontab.guru/ to WISIWIG interface. | ||
Timezone is UT | ||
auto_deploy: | ||
type: boolean | ||
description: | | ||
Specify if the job will be automatically updated after receiving a new image tag or a new commit according to the source type. | ||
The new image tag shall be communicated via the "Auto Deploy job" endpoint https://api-doc.qovery.com/#tag/Jobs/operation/autoDeployJobEnvironments | ||
oneOf: | ||
- $ref: './LifecycleJobResponse.yaml' | ||
- $ref: './CronJobResponse.yaml' | ||
discriminator: | ||
propertyName: job_type | ||
mapping: | ||
LIFECYCLE: '#/components/schemas/LifecycleJobResponse' | ||
CRON: '#/components/schemas/CronJobResponse' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.