-
Notifications
You must be signed in to change notification settings - Fork 282
/
Copy pathrepo.yaml
22 lines (18 loc) · 954 Bytes
/
repo.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# -*- coding: utf-8 -*-
# vim: ft=yaml
---
# 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 %}
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) }}
cluster_name: {{ salt['pillar.get']('postgres:cluster:name', defaults.postgres.cluster.name) }}
#Early lookup for system user on MacOS
{% if grains.os == 'MacOS' %}
{% 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")) %}
user: {{ sysuser }}
group: {{ sysgroup }}
{% endif %}
# vim: ft=sls