community/autologin: new aport

This commit is contained in:
Oliver Smith 2020-12-15 14:29:53 +01:00 committed by Leo
parent 7b4f0ef974
commit 0878a74d73
2 changed files with 57 additions and 0 deletions

View File

@ -0,0 +1,27 @@
# Maintainer: Oliver Smith <ollieparanoid@postmarketos.org>
# Contributor: Oliver Smith <ollieparanoid@postmarketos.org>
pkgname=autologin
pkgver=1.0.0
pkgrel=0
pkgdesc="Daemon for automatic login on TTY"
url="https://git.sr.ht/~kennylevinsen/autologin"
arch="all"
license="GPL-3.0-only"
makedepends="meson linux-pam-dev linux-headers"
options="!check" # No tests
source="autologin-$pkgver.tar.gz::https://git.sr.ht/~kennylevinsen/autologin/archive/$pkgver.tar.gz
autologin.pamd
"
build() {
abuild-meson . output
meson compile ${JOBS:+-j ${JOBS}} -C output
}
package() {
DESTDIR="$pkgdir" meson install -C output
install -Dm644 "$srcdir"/autologin.pamd "$pkgdir"/etc/pam.d/autologin
}
sha512sums="5a6d128acede98278a3de23da13ae48a692cbcdbdb16519327b58e090fbf177b8e44093a161d04787135da57e67c4819a0907359d94b80baa9cd170610cb056c autologin-1.0.0.tar.gz
4427a41eb5d841f2eddd2c976d6694da7a02adf392fe68323fdb5b9da143efa53fccf271ffe931ff144cc50d19b8138f362ca2819704f49ae326d7c60339ab4b autologin.pamd"

View File

@ -0,0 +1,30 @@
#%PAM-1.0
# Block login if they are globally disabled
auth required pam_nologin.so
# Load environment from /etc/environment and ~/.pam_environment
auth required pam_env.so
# Allow access without authentication
auth required pam_permit.so
# Stop autologin if account requires action
account required pam_unix.so
# Can't change password
password required pam_deny.so
# Setup session
session required pam_unix.so
session optional pam_elogind.so
# Unlock GNOME Keyring if available
-auth optional pam_gnome_keyring.so
-session optional pam_gnome_keyring.so auto_start
# Unlock KWallet if available
-auth optional pam_kwallet.so
-auth optional pam_kwallet5.so
-session optional pam_kwallet.so auto_start
-session optional pam_kwallet5.so auto_start