Sha256: db2ebb280791ec84409147efbe14a7eb9eba2aea5a819e238b69f075dd8a998d

Contents?: true

Size: 388 Bytes

Versions: 125

Compression:

Stored size: 388 Bytes

Contents

class Specinfra::Command::Base::MailAlias < Specinfra::Command::Base
  class << self
    def check_is_aliased_to(mail_alias, recipient)
      recipient = "[[:space:]]([\"']?)#{recipient}\\1"
      "getent aliases #{escape(mail_alias)} | egrep -- #{escape(recipient)}$"
    end

    def add(mail_alias, recipient)
      "echo #{mail_alias}: #{recipient} >> /etc/aliases"
    end
  end
end

Version data entries

125 entries across 125 versions & 2 rubygems

Version Path
specinfra-2.19.4 lib/specinfra/command/base/mail_alias.rb
specinfra-2.19.3 lib/specinfra/command/base/mail_alias.rb
specinfra-2.19.2 lib/specinfra/command/base/mail_alias.rb
specinfra-2.19.1 lib/specinfra/command/base/mail_alias.rb
specinfra-2.19.0 lib/specinfra/command/base/mail_alias.rb
specinfra-2.18.3 lib/specinfra/command/base/mail_alias.rb
specinfra-2.18.2 lib/specinfra/command/base/mail_alias.rb
specinfra-2.18.1 lib/specinfra/command/base/mail_alias.rb
specinfra-2.18.0 lib/specinfra/command/base/mail_alias.rb
specinfra-2.17.1 lib/specinfra/command/base/mail_alias.rb
specinfra-2.17.0 lib/specinfra/command/base/mail_alias.rb
specinfra-2.16.0 lib/specinfra/command/base/mail_alias.rb
specinfra-2.15.2 lib/specinfra/command/base/mail_alias.rb
specinfra-2.15.1 lib/specinfra/command/base/mail_alias.rb
specinfra-2.15.0 lib/specinfra/command/base/mail_alias.rb
specinfra-2.14.4 lib/specinfra/command/base/mail_alias.rb
specinfra-2.14.3 lib/specinfra/command/base/mail_alias.rb
specinfra-2.14.2 lib/specinfra/command/base/mail_alias.rb
specinfra-2.14.1 lib/specinfra/command/base/mail_alias.rb
specinfra-2.14.0 lib/specinfra/command/base/mail_alias.rb