機械翻訳について

ジョブの再起動

post

/api/v2/jobs/{id}/relaunch/

このリソースに対してPOSTリクエストを行って、ジョブを起動します。 パスワードまたは変数が必要な場合は、POSTデータを介して渡す必要があります。 このジョブ・テンプレートに基づくジョブの起動に必要な値を決定するために、このエンドポイントにGETリクエストを実行できます。

リクエスト

サポートされているメディア・タイプ
パス・パラメータ
本文()
ルート・スキーマ : schema
例:
{
    "hosts":"failed"
}
先頭に戻る

レスポンス

サポートされているメディア・タイプ

201レスポンス

本文
レスポンスの例(application/json)
{
    "allow_simultaneous":false,
    "artifacts":{
    },
    "canceled_on":null,
    "controller_node":"",
    "created":"2018-02-01T08:00:00.000000Z",
    "description":"",
    "diff_mode":false,
    "elapsed":0,
    "event_processing_finished":false,
    "execution_node":"",
    "extra_vars":"{}",
    "failed":false,
    "finished":null,
    "force_handlers":false,
    "forks":0,
    "id":2,
    "instance_group":null,
    "inventory":1,
    "job":2,
    "job_args":"",
    "job_cwd":"",
    "job_env":{
    },
    "job_explanation":"",
    "job_slice_count":1,
    "job_slice_number":0,
    "job_tags":"",
    "job_template":2,
    "job_type":"run",
    "launch_type":"relaunch",
    "limit":"host3",
    "modified":"2018-02-01T08:00:00.000000Z",
    "name":"testjt",
    "organization":1,
    "passwords_needed_to_start":[
    ],
    "playbook":"",
    "project":1,
    "related":{
        "activity_stream":"/api/v2/jobs/2/activity_stream/",
        "cancel":"/api/v2/jobs/2/cancel/",
        "create_schedule":"/api/v2/jobs/2/create_schedule/",
        "credentials":"/api/v2/jobs/2/credentials/",
        "inventory":"/api/v2/inventories/1/",
        "job_events":"/api/v2/jobs/2/job_events/",
        "job_host_summaries":"/api/v2/jobs/2/job_host_summaries/",
        "job_template":"/api/v2/job_templates/2/",
        "labels":"/api/v2/jobs/2/labels/",
        "notifications":"/api/v2/jobs/2/notifications/",
        "organization":"/api/v2/organizations/1/",
        "project":"/api/v2/projects/1/",
        "relaunch":"/api/v2/jobs/2/relaunch/",
        "stdout":"/api/v2/jobs/2/stdout/",
        "unified_job_template":"/api/v2/job_templates/2/"
    },
    "result_traceback":"",
    "scm_branch":"",
    "scm_revision":"",
    "skip_tags":"",
    "start_at_task":"",
    "started":null,
    "status":"pending",
    "summary_fields":{
        "credentials":[
            {
                "cloud":false,
                "description":"",
                "id":1,
                "kind":"ssh",
                "name":"machine-cred"
            }
        ],
        "inventory":{
            "description":"",
            "has_active_failures":false,
            "has_inventory_sources":false,
            "hosts_with_active_failures":0,
            "id":1,
            "inventory_sources_with_failures":0,
            "kind":"",
            "name":"test-inv",
            "organization_id":1,
            "total_groups":0,
            "total_hosts":0,
            "total_inventory_sources":0
        },
        "job_template":{
            "description":"",
            "id":2,
            "name":"testjt"
        },
        "labels":{
            "count":0,
            "results":[
            ]
        },
        "organization":{
            "description":"test-org-desc",
            "id":1,
            "name":"test-org"
        },
        "project":{
            "description":"test-proj-desc",
            "id":1,
            "name":"test-proj",
            "scm_type":"git",
            "status":"never updated"
        },
        "unified_job_template":{
            "description":"",
            "id":2,
            "name":"testjt",
            "unified_job_type":"job"
        },
        "user_capabilities":{
            "delete":true,
            "start":true
        }
    },
    "timeout":0,
    "type":"job",
    "unified_job_template":2,
    "url":"/api/v2/jobs/2/",
    "use_fact_cache":false,
    "verbosity":0,
    "webhook_credential":null,
    "webhook_guid":"",
    "webhook_service":""
}

403レスポンス

本文
レスポンスの例(application/json)
{
    "detail":"Job was launched with secret prompts provided by another user."
}
先頭に戻る