diff options
author | sukanka | 2023-07-30 22:17:16 +0800 |
---|---|---|
committer | sukanka | 2023-07-30 22:17:16 +0800 |
commit | cb2cc28c03c007eb9bf435f709307da3001e6dc2 (patch) | |
tree | 4f50d9df7666132250d71796bf3864daca68534a | |
parent | ce0dcf60dbd56cf4195d5eac76a0f997697fe58e (diff) | |
download | aur-cb2cc28c03c007eb9bf435f709307da3001e6dc2.tar.gz |
update to 3.24.0
-rw-r--r-- | .SRCINFO | 16 | ||||
-rw-r--r-- | PKGBUILD | 23 | ||||
-rw-r--r-- | alist.install | 17 | ||||
-rw-r--r-- | alist.service | 8 | ||||
-rw-r--r-- | alist.sysusers | 2 | ||||
-rw-r--r-- | alist.tmpfiles | 7 | ||||
-rw-r--r-- | config.json | 56 |
7 files changed, 76 insertions, 53 deletions
@@ -1,6 +1,6 @@ pkgbase = alist pkgdesc = File list program that supports multiple storage - pkgver = 3.16.3 + pkgver = 3.24.0 pkgrel = 1 url = https://github.com/alist-org/alist install = alist.install @@ -10,17 +10,21 @@ pkgbase = alist arch = armv6h arch = arm7vh arch = aarch64 + arch = riscv64 + arch = loong64 license = AGPL3 makedepends = go depends = glibc backup = etc/alist/config.json - source = alist-3.16.3.tar.gz::https://github.com/alist-org/alist/archive/v3.16.3.tar.gz + source = alist-3.24.0.tar.gz::https://github.com/alist-org/alist/archive/v3.24.0.tar.gz source = alist.service source = alist.tmpfiles + source = alist.sysusers source = config.json - sha256sums = 541598a1238720256053fa9fec2091edffd2223a2faad19062b38393d35975f0 - sha256sums = b96d55f7e83310a7556a5b023be60e12f44c484e3e136f1488d737126c9ed34f - sha256sums = 48eb4f8f1070cfd2f9594fe72cb4b1a35fce091251fda11e2082f573f62ac12b - sha256sums = ba9cd5b593313183ad8c0f008a6edba539063193c416d3893a5344e104a3fff1 + sha256sums = d2a9d81fc9da53ecb4c0036e52bb4d1b5af08de56fe456fa6b495b29659c7d67 + sha256sums = 5712b21aebf669fe9fb5d47dd685809d4d9670b1bb1d5e6fef962b9d11ba9d72 + sha256sums = c6b62c4a750ab921c2e8f965e4baeee28855c9a969b00eddd346670f2fdf12de + sha256sums = 3658370660806f73c3d9bc5f1b6e2a013c9520d34ffc4462df99f7692473613d + sha256sums = b72f194a7b8855e97eeb76e63e179f38132cc9e6be9daa5b396699c9c11611de pkgname = alist @@ -1,12 +1,10 @@ # Maintainer: Luis Martinez <luis dot martinez at disroot dot org> -## Credit to ayatale for the systemd and config files - pkgname=alist -pkgver=3.16.3 +pkgver=3.24.0 pkgrel=1 pkgdesc="File list program that supports multiple storage" -arch=('x86_64' 'i686' 'arm' 'armv6h' 'arm7vh' 'aarch64') +arch=('x86_64' 'i686' 'arm' 'armv6h' 'arm7vh' 'aarch64' 'riscv64' 'loong64') url="https://github.com/alist-org/alist" license=('AGPL3') depends=('glibc') @@ -16,11 +14,13 @@ install=alist.install source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz" 'alist.service' 'alist.tmpfiles' + 'alist.sysusers' 'config.json') -sha256sums=('541598a1238720256053fa9fec2091edffd2223a2faad19062b38393d35975f0' - 'b96d55f7e83310a7556a5b023be60e12f44c484e3e136f1488d737126c9ed34f' - '48eb4f8f1070cfd2f9594fe72cb4b1a35fce091251fda11e2082f573f62ac12b' - 'ba9cd5b593313183ad8c0f008a6edba539063193c416d3893a5344e104a3fff1') +sha256sums=('d2a9d81fc9da53ecb4c0036e52bb4d1b5af08de56fe456fa6b495b29659c7d67' + '5712b21aebf669fe9fb5d47dd685809d4d9670b1bb1d5e6fef962b9d11ba9d72' + 'c6b62c4a750ab921c2e8f965e4baeee28855c9a969b00eddd346670f2fdf12de' + '3658370660806f73c3d9bc5f1b6e2a013c9520d34ffc4462df99f7692473613d' + 'b72f194a7b8855e97eeb76e63e179f38132cc9e6be9daa5b396699c9c11611de') prepare() { cd "$pkgname-$pkgver" @@ -57,7 +57,8 @@ package() { cd "$pkgname-$pkgver" install -Dv "build/$pkgname" -t "$pkgdir/usr/bin/" install -Dvm644 README.md -t "$pkgdir/usr/share/doc/$pkgname/" - install -Dvm644 "$srcdir/alist.service" -t "$pkgdir/usr/lib/systemd/system/" - install -Dvm644 "$srcdir/alist.tmpfiles" "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf" - install -Dvm644 "$srcdir/config.json" -t "$pkgdir/etc/$pkgname/" + install -Dvm644 "${srcdir}/alist.service" -t "${pkgdir}/usr/lib/systemd/system/" + install -Dvm644 "${srcdir}/config.json" -t "${pkgdir}/etc/${pkgname}" + install -Dvm644 "${srcdir}/alist.sysusers" "${pkgdir}/usr/lib/sysusers.d/${pkgname}.conf" + install -Dvm644 "${srcdir}/alist.tmpfiles" "${pkgdir}/usr/lib/tmpfiles.d/${pkgname}.conf" } diff --git a/alist.install b/alist.install index b8f8719c7b32..6f4dfb677091 100644 --- a/alist.install +++ b/alist.install @@ -1,9 +1,12 @@ post_upgrade(){ - echo -e "\033[31m If you're upgrading from below 2.1.0-7 \033[0m" - echo -e "\033[31m Please move your db file ( perhaps /usr/bin/data/data.db) to /var/lib/alist/data.db \033[0m" - echo "You can run " - echo -e "\033[31m sudo systemctl stop alist \033[0m" - echo -e "\033[31m sudo mv /usr/bin/data/data.db /var/lib/alist/data.db \033[0m" - echo -e "\033[31m sudo systemctl start alist \033[0m" - echo -e "\033[31m sudo rm -rf /usr/bin/data \033[0m" + echo "from alist 3.24.0, the alist user is used to run this service" + echo "if you are upgrading from a previous version" + echo "you have to run the following commands in green only once" + + echo -e "\e[32m sudo chown -R alist:alist /var/lib/alist \e[0m" + echo -e "\e[32m sudo chown -R alist:alist /var/log/alist \e[0m" + echo -e "\e[32m sudo chown -R alist:alist /etc/alist \e[0m" + echo -e "\e[32m sudo chown -R alist:alist /var/cache/alist \e[0m" + + echo "and chown any other local files that are served by alist" } diff --git a/alist.service b/alist.service index 1f9088a46444..7a06273269a3 100644 --- a/alist.service +++ b/alist.service @@ -1,11 +1,13 @@ [Unit] Description=alist -After=network.target +Wants=network-online.target +After=network-online.target [Service] Type=simple -WorkingDirectory=/usr/bin -ExecStart=/usr/bin/alist -conf /etc/alist/config.json +User=alist +WorkingDirectory=/var/lib/alist +ExecStart=/usr/bin/alist server --data /var/lib/alist Restart=on-failure [Install] diff --git a/alist.sysusers b/alist.sysusers new file mode 100644 index 000000000000..761d215044b9 --- /dev/null +++ b/alist.sysusers @@ -0,0 +1,2 @@ +#Type Name ID GECOS Home directory Shell +u alist - "A file list program" /var/lib/alist diff --git a/alist.tmpfiles b/alist.tmpfiles index ffbf3be1a52e..33ec921c7ca6 100644 --- a/alist.tmpfiles +++ b/alist.tmpfiles @@ -1 +1,6 @@ -d /var/lib/alist +#Type Path Mode User Group Age Argument +d /var/lib/alist 0755 alist alist - - +d /var/log/alist 0755 alist alist - - +d /var/cache/alist 0755 alist alist - - +d /etc/alist 0755 alist alist - - +L /etc/alist/config.json 0644 alist alist - /var/lib/alist/config.json diff --git a/config.json b/config.json index 58a1330d9758..6b377e71d843 100644 --- a/config.json +++ b/config.json @@ -1,26 +1,32 @@ { - "address": "0.0.0.0", - "port": 5244, - "assets": "jsdelivr", - "database": { - "type": "sqlite3", - "user": "", - "password": "", - "host": "", - "port": 0, - "name": "", - "table_prefix": "x_", - "db_file": "/var/lib/alist/data.db", - "ssl_mode": "disable" - }, - "scheme": { - "https": false, - "cert_file": "", - "key_file": "" - }, - "cache": { - "expiration": 60, - "cleanup_interval": 120 - }, - "temp_dir": "/var/cache/alist/temp" -}
\ No newline at end of file + "force": false, + "address": "0.0.0.0", + "port": 5244, + "jwt_secret": "random generated", + "cdn": "", + "database": { + "type": "sqlite3", + "host": "", + "port": 0, + "user": "", + "password": "", + "name": "", + "db_file": "/var/lib/alist/data.db", + "ssl_mode": "disable", + "table_prefix": "x_" + }, + "scheme": { + "https": false, + "cert_file": "", + "key_file": "" + }, + "temp_dir": "/var/cache/alist/temp", + "log": { + "enable": false, + "name": "/var/log/alist/log.log", + "max_size": 10, + "max_backups": 5, + "max_age": 28, + "compress": false + } +} |