POSTLOCK(1)

πŸ“¦
version 3.11.7 Β· 3 versions
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, debian trixie, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’Œ postlock(1) β€” General Commands Manual πŸ’Œ

ok so bestie, let me put you on to postlock β€” it locks a mail folder and then runs your command. yes literally. she's from the General Commands Manual and she's about to be your new fave. πŸŽ€


✨ NAME ✨

postlock β€” lock mail folder and execute command πŸ¦‹


🌸 SYNOPSIS 🌸

postlock [-c config_dir] [-l lock_style]
        [-v] file command...

πŸ’– DESCRIPTION πŸ’–

okay so the postlock(1) command locks file for exclusive access, and then executes command. that's the whole vibe. and the way she locks things? it's compatible with the Postfix UNIX-style local delivery agent β€” so she fits right in, no cap. πŸ’…

Options, bestie:

  • -c config_dir β€” read the main.cf configuration file in the named directory instead of the default configuration directory.
  • -l lock_style β€” override the locking method that's specified via the mailbox_delivery_lock configuration parameter (scroll down, she's there πŸ‘‡).
  • -v β€” enable verbose logging for debugging purposes. and like, stack them? multiple -v options make the software increasingly verbose. louder. louder. LOUDER. πŸ”₯

Arguments, bestie:

  • file β€” a mailbox file. the user should have read/write permission. (yes, permission. she will not be gatekept. πŸ™ˆ)
  • command... β€” the command to execute while file is locked for exclusive access. and listen: the command is executed directly, i.e. without interpretation by a shell command interpreter. no shell, no middleman, no drama. she's her own main character. πŸ‘‘

😭 DIAGNOSTICS 😭

the result status is 75 (EX_TEMPFAIL) when postlock(1) could not perform the requested operation. like, she tried, okay? otherwise, the exit status is the exit status from the command. periodt. πŸ’€


🚨 BUGS 🚨

with remote file systems, the ability to acquire a lock does not necessarily eliminate access conflicts. avoid file access by processes running on different machines. fr fr, do not test her on this one. πŸ’€

🌈 ENVIRONMENT 🌈

  • MAIL_CONFIG β€” directory with Postfix configuration files.
  • MAIL_VERBOSE β€” enable verbose logging for debugging purposes.

πŸ‘‘ CONFIGURATION PARAMETERS πŸ‘‘

the following main.cf parameters are especially relevant to this program. the text below provides only a parameter summary β€” see postconf(5) for more details including examples. (she's not being mysterious, she's just being brief. iykyk ✨)

πŸ”’ LOCKING CONTROLS πŸ”’

  • deliver_lock_attempts (20) β€” the maximal number of attempts to acquire an exclusive lock on a mailbox file or bounce(8) logfile.
  • deliver_lock_delay (1s) β€” the time between attempts to acquire an exclusive lock on a mailbox file or bounce(8) logfile.
  • stale_lock_time (500s) β€” the time after which a stale exclusive mailbox lockfile is removed.
  • mailbox_delivery_lock (see 'postconf -d' output) β€” how to lock a UNIX-style local(8) mailbox before attempting delivery.

πŸ“ RESOURCE AND RATE CONTROLS πŸ“

  • fork_attempts (5) β€” the maximal number of attempts to fork() a child process.
  • fork_delay (1s) β€” the delay between attempts to fork() a child process.

🧚 MISCELLANEOUS CONTROLS 🧚

  • config_directory (see 'postconf -d' output) β€” the default location of the Postfix main.cf and master.cf configuration files.
  • import_environment (see 'postconf -d' output) β€” the list of environment variables that a privileged Postfix process will import from a non-Postfix parent process, or name=value environment overrides.

πŸ‘€ SEE ALSO πŸ‘€

postconf(5), configuration parameters 🌟


πŸ“œ LICENSE πŸ“œ

the Secure Mailer license must be distributed with this software. it's giving legal slay, don't skip it. πŸ’–


πŸ’œ AUTHOR(S) πŸ’œ

Wietse Venema IBM T.J. Watson Research P.O. Box 704 Yorktown Heights, NY 10598, USA

Wietse Venema Google, Inc. 111 8th Avenue New York, NY 10011, USA


ok that's the whole page bestie, you ate that 🫢 go lock something and run something, she's iconic for it. and just so we're cute about it: this was postlock(1) from the General Commands Manual, page postlock(1). bye bestie, stay locked and loaded πŸ’…βœ¨πŸŒΈ

πŸ“¦ where this page comes from