GET /api/settings
Llista tots els ajusts

Examples

GET /api/settings
200
{
  "total": 85,
  "subtotal": 85,
  "page": 1,
  "per_page": 20,
  "search": null,
  "sort": {
    "by": null,
    "order": null
  },
  "results": [
    {
      "value": "http://foreman.some.host.fqdn",
      "description": "The URL Foreman should point to in emails etc",
      "category": "Setting::General",
      "settings_type": null,
      "default": "http://foreman.some.host.fqdn",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 182539440,
      "name": "foreman_url",
      "full_name": null,
      "category_name": "General"
    },
    {
      "value": null,
      "description": "Default root password on provisioned hosts",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": null,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 1038509113,
      "name": "root_pass",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": true,
      "description": "Enable safe mode config templates rendinging(recommended)",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": true,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 595784092,
      "name": "safemode_render",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": "/var/lib/puppet/ssl/certs/some.host.fqdn",
      "description": "SSL Certificate path that foreman would use to communicate with its proxies",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": "/var/lib/puppet/ssl/certs/some.host.fqdn",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 344310031,
      "name": "ssl_certificate",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": "/var/lib/puppet/ssl/certs/ca.pem",
      "description": "SSL CA file that foreman would use to communicate with its proxies",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": "/var/lib/puppet/ssl/certs/ca.pem",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 227315895,
      "name": "ssl_ca_file",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": "/var/lib/puppet/ssl/private_keys/super.some.host.fqdn.pem",
      "description": "SSL Private Key file that foreman would use to communicate with its proxies",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": "/var/lib/puppet/ssl/private_keys/super.some.host.fqdn.pem",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 982229024,
      "name": "ssl_priv_key",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": 30,
      "description": "Setting::Puppet interval in minutes",
      "category": "Setting::Puppet",
      "settings_type": "integer",
      "default": 30,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 708099507,
      "name": "puppet_interval",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": "production",
      "description": "The Setting::Puppet environment foreman would default to in case it can't auto detect it",
      "category": "Setting::Puppet",
      "settings_type": null,
      "default": "production",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 489917738,
      "name": "default_puppet_environment",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": false,
      "description": "Enable Email Alerts per each failed puppet report",
      "category": "Setting::Puppet",
      "settings_type": null,
      "default": false,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 14451317,
      "name": "failed_report_email_notification",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": [
        "fqdn",
        "hostgroup",
        "os",
        "domain"
      ],
      "description": "The Default path in which foreman resolves host specific variables",
      "category": "Setting::Puppet",
      "settings_type": null,
      "default": [
        "fqdn",
        "hostgroup",
        "os",
        "domain"
      ],
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 515381208,
      "name": "Default_variables_Lookup_Path",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": true,
      "description": "Should Foreman manage host certificates when provisioning hosts",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": true,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 700393283,
      "name": "manage_puppetca",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": 20,
      "description": "The amount of records shown per page in foreman",
      "category": "Setting::General",
      "settings_type": null,
      "default": 20,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 817264379,
      "name": "entries_per_page",
      "full_name": null,
      "category_name": "General"
    },
    {
      "value": false,
      "description": "Foreman will update a hosts environment from its facts",
      "category": "Setting::Puppet",
      "settings_type": null,
      "default": false,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 129058412,
      "name": "update_environment_from_facts",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": 5,
      "description": "idle timeout",
      "category": "Setting::General",
      "settings_type": null,
      "default": 5,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 386817023,
      "name": "idle_timeout",
      "full_name": null,
      "category_name": "General"
    },
    {
      "value": true,
      "description": "Should Foreman provide puppet environment in ENC yaml output? (this avoids the mismatch error between puppet.conf and ENC environment)",
      "category": "Setting::Puppet",
      "settings_type": null,
      "default": true,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 537488238,
      "name": "enc_environment",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": false,
      "description": "Should Foreman use random UUID's for certificate signing instead of hostnames",
      "category": "Setting::Puppet",
      "settings_type": null,
      "default": false,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 855146510,
      "name": "use_uuid_for_certificates",
      "full_name": null,
      "category_name": "Puppet"
    },
    {
      "value": false,
      "description": "Should Foreman query the locally configured name server or the SOA/NS authorities",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": false,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 100642973,
      "name": "query_local_nameservers",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": "127.0.0",
      "description": "If Foreman is running behind Passenger or a remote loadbalancer, the ip should be set here",
      "category": "Setting::Provisioning",
      "settings_type": null,
      "default": "127.0.0",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 485941537,
      "name": "remote_addr",
      "full_name": null,
      "category_name": "Provisioning"
    },
    {
      "value": false,
      "description": "Setting::Authorize login delegation with REMOTE_USER environment variable",
      "category": "Setting::General",
      "settings_type": null,
      "default": false,
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 737268150,
      "name": "authorize_login_delegation",
      "full_name": null,
      "category_name": "General"
    },
    {
      "value": "root@some.host.fqdn",
      "description": "The Default administrator email address",
      "category": "Setting::General",
      "settings_type": "string",
      "default": "root@some.host.fqdn",
      "created_at": "2019-11-07 08:52:01 UTC",
      "updated_at": "2019-11-07 08:52:01 UTC",
      "id": 333972760,
      "name": "administrator",
      "full_name": null,
      "category_name": "General"
    }
  ]
}

Params

Param Name Description
location_id
Optional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
Optional

Set the current organization context for the request

Validations:

  • Must be a Integer

search
Optional

filtra els resultats

Validations:

  • Must be a String

order
Optional

Sort field and order, eg. ‘id DESC’

Validations:

  • Must be a String

page
Optional

Page number, starting at 1

Validations:

  • Must be a number.

per_page
Optional

Nombre de resultats per pàgina a retornar

Validations:

  • Must be a number.

Search fields

Field name Tipus Possible values
description text
name string

GET /api/settings/:id
Mostra un ajust

Examples

GET /api/settings/administrator
200
{
  "value": "root@some.host.fqdn",
  "description": "The Default administrator email address",
  "category": "Setting::General",
  "settings_type": "string",
  "default": "root@some.host.fqdn",
  "created_at": "2019-11-07 08:52:01 UTC",
  "updated_at": "2019-11-07 08:52:01 UTC",
  "id": 333972760,
  "name": "administrator",
  "full_name": null,
  "category_name": "General"
}

Params

Param Name Description
location_id
Optional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
Optional

Set the current organization context for the request

Validations:

  • Must be a Integer

id
Required

Validations:

  • Must be a String


PUT /api/settings/:id
Actualitza un ajust

Examples

PUT /api/settings/426558050
{
  "setting": {
    "value": "BGxSfJdnrKiIHRokLxVORUfXnPFkrwSnDiBGxgEDhtKfJlyESVHwtegCswbgmOSpBzjisowMICihwxrLEOSqDAfrpgcnnycyNDxYMngimFosqwBeiGVdoecCmmPsjzelgyEmlrQBVbreNCKflDMMxMWcyhXGsykdOwJqjhqBJmQQhRYXIAoFxcWzTuwSApazqdXxBXRpLOSEpFRLEzALEktPdMUrbkUgRhYcoAOHoVhnwBHLBKCxzvBJpKUuTXpeqMKoaLAUTCUduJwTINAlYSGQcqQpkUPKBUrPplbzXiGPolAVaGpciCCOQnXQrCNXNtStIckWufrbQdpfgyyCKlcOTrChvjxsSeKvyaooraCxXhalonbQdLUDPaVRwlTbKbHnqcJUmlwxGaTwgURWugHQOvOuNKAindRSNWluxqVbpagVIvYOrupcLIAEKDImBkgMWvbmuUmeFejLiBLqdVzcWOhCgMtYyAITxbyIfRoOPPNrGmFCCCGfDLJLnSGewCGAXDtBtVhaVRFHKSIjHbAthkWQxaISyplyctkpUIBMalwAiCwWXoNTApWxwRFidgugJjWqiWjhJzElXIktrLGsIsklvslRbjvplfjFOROCKCVxquXRpDltVXNvdlTJisiaSDiQiPONhnOeeyXRdcKTOxaXAFPaHmydVHcNkRHczoeenibXyfNAUtpXzScyNKAKpxFbNqPovtuwbVJVFsVfSwLjQikBDaCOWxVMQnhtsWEaikgsczFWKKcHxWluEDQmMRUOmsXltfMDIPzNFVCvabjdEGDYjGAAfLJmdeiFoYoDDzbdFTVAatGbFKdiJWXJgHJuYFsijNwmXiynNGDDOoDaEkVNnimlsEeClqRzCAjBkBBTbJuqeFRqFArHguvheMclatVLLoKqTjndQtziDKAAdvVYgwFExnYLMRgBFAGfBLKTJNeyceocgXEVHPDalfjmFmedfOSJNDifPyewLywQwNXvSiqXooQJ"
  }
}
200
{
  "value": "BGxSfJdnrKiIHRokLxVORUfXnPFkrwSnDiBGxgEDhtKfJlyESVHwtegCswbgmOSpBzjisowMICihwxrLEOSqDAfrpgcnnycyNDxYMngimFosqwBeiGVdoecCmmPsjzelgyEmlrQBVbreNCKflDMMxMWcyhXGsykdOwJqjhqBJmQQhRYXIAoFxcWzTuwSApazqdXxBXRpLOSEpFRLEzALEktPdMUrbkUgRhYcoAOHoVhnwBHLBKCxzvBJpKUuTXpeqMKoaLAUTCUduJwTINAlYSGQcqQpkUPKBUrPplbzXiGPolAVaGpciCCOQnXQrCNXNtStIckWufrbQdpfgyyCKlcOTrChvjxsSeKvyaooraCxXhalonbQdLUDPaVRwlTbKbHnqcJUmlwxGaTwgURWugHQOvOuNKAindRSNWluxqVbpagVIvYOrupcLIAEKDImBkgMWvbmuUmeFejLiBLqdVzcWOhCgMtYyAITxbyIfRoOPPNrGmFCCCGfDLJLnSGewCGAXDtBtVhaVRFHKSIjHbAthkWQxaISyplyctkpUIBMalwAiCwWXoNTApWxwRFidgugJjWqiWjhJzElXIktrLGsIsklvslRbjvplfjFOROCKCVxquXRpDltVXNvdlTJisiaSDiQiPONhnOeeyXRdcKTOxaXAFPaHmydVHcNkRHczoeenibXyfNAUtpXzScyNKAKpxFbNqPovtuwbVJVFsVfSwLjQikBDaCOWxVMQnhtsWEaikgsczFWKKcHxWluEDQmMRUOmsXltfMDIPzNFVCvabjdEGDYjGAAfLJmdeiFoYoDDzbdFTVAatGbFKdiJWXJgHJuYFsijNwmXiynNGDDOoDaEkVNnimlsEeClqRzCAjBkBBTbJuqeFRqFArHguvheMclatVLLoKqTjndQtziDKAAdvVYgwFExnYLMRgBFAGfBLKTJNeyceocgXEVHPDalfjmFmedfOSJNDifPyewLywQwNXvSiqXooQJ",
  "description": "Text to be shown in the login-page footer",
  "category": "Setting::General",
  "settings_type": null,
  "default": null,
  "created_at": "2019-11-07 08:52:01 UTC",
  "updated_at": "2019-11-07 08:52:08 UTC",
  "id": 426558050,
  "name": "login_text",
  "full_name": null,
  "category_name": "General"
}

Params

Param Name Description
location_id
Optional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
Optional

Set the current organization context for the request

Validations:

  • Must be a Integer

id
Required

Validations:

  • Must be a String

setting
Required

Validations:

  • Must be a Hash

setting[value]
Optional

Validations:

  • Must be a String