# ------------------------------------------------------------------
#
#    Copyright (C) 2002-2006 Novell/SUSE
#    Copyright (C) 2018 Canonical, Ltd.
#    Copyright (C) 2019 Christian Boltz
#
#    This program is free software; you can redistribute it and/or
#    modify it under the terms of version 2 of the GNU General Public
#    License published by the Free Software Foundation.
#
# ------------------------------------------------------------------

abi <abi/4.0>,

include <tunables/global>

@{att}=/att/postfix-proxymap/
profile postfix-proxymap /usr/lib{,exec}/postfix/{bin/,sbin/,}proxymap flags=(attach_disconnected.path=@{att}) {
  include <abstractions/base>
  include <abstractions/nameservice>
  include <abstractions/postfix-common>

  @{att}/postfix-proxymap/run/mysql/mysql.sock w,
  @{att}@{run}/mysql/mysql.sock rw,
  @{att}@{run}/systemd/userdb/io.systemd.DynamicUser rw,
  @{att}@{run}/systemd/userdb/io.systemd.Machine rw,
  @{att}/systemd/journal/dev-log w,


  /etc/my.cnf r,
  /etc/my.cnf.d/ r,
  /etc/my.cnf.d/*.cnf r,

  /usr/lib{,exec}/postfix/{bin/,sbin/,}proxymap     mrix,
  /{var/spool/postfix/,}private/proxymap            rw,

  # Site-specific additions and overrides. See local/README for details.
  include if exists <local/postfix-proxymap>
}
