2019-08-06 20:56:45 +01:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
# vim: ft=yaml
|
|
|
|
---
|
2016-09-23 17:50:57 +03:00
|
|
|
# This file allows to get PostgreSQL version and upstream repo settings
|
|
|
|
# early from Pillar to set correct lookup dictionaty items
|
|
|
|
|
|
|
|
{% import_yaml "postgres/defaults.yaml" as defaults %}
|
|
|
|
|
2018-04-09 14:59:49 +01:00
|
|
|
use_upstream_repo: {{ salt['pillar.get']('postgres:use_upstream_repo', defaults.postgres.use_upstream_repo) }}
|
|
|
|
version: {{ salt['pillar.get']('postgres:version', defaults.postgres.version) }}
|
|
|
|
fromrepo: {{ salt['pillar.get']('postgres:fromrepo', defaults.postgres.fromrepo) }}
|
2018-06-21 08:30:08 +01:00
|
|
|
cluster_name: {{ salt['pillar.get']('postgres:cluster:name', defaults.postgres.cluster.name) }}
|
2016-09-23 17:50:57 +03:00
|
|
|
|
2018-03-08 11:41:19 +00:00
|
|
|
#Early lookup for system user on MacOS
|
|
|
|
{% if grains.os == 'MacOS' %}
|
2018-06-21 08:34:58 +01:00
|
|
|
{% set sysuser = salt['pillar.get']('postgres:user', salt['cmd.run']("stat -f '%Su' /dev/console")) %}
|
|
|
|
{% set sysgroup = salt['pillar.get']('postgres:group', salt['cmd.run']("stat -f '%Sg' /dev/console")) %}
|
2018-03-08 11:41:19 +00:00
|
|
|
user: {{ sysuser }}
|
|
|
|
group: {{ sysgroup }}
|
|
|
|
{% endif %}
|
|
|
|
|
2016-09-23 17:50:57 +03:00
|
|
|
# vim: ft=sls
|