-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #28 from hmlendea/gandi-dns-updater
gandi-dns-updater: Added the package
- Loading branch information
Showing
3 changed files
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
pkgname=gandi-dns-updater | ||
pkgver=1.0.0 | ||
pkgrel=1 | ||
pkgdesc="CLI utility for updating Gandi.net DNS records" | ||
arch=('any') | ||
url="https://github.com/hmlendea/${pkgname}" | ||
license=('GPL') | ||
depends=('curl') | ||
optdepends=('bind: For IP address detection' | ||
'iputils: For IP address detection') | ||
install= | ||
source=(https://github.com/hmlendea/${pkgname}/releases/download/v${pkgver}/${pkgname}.sh) | ||
sha512sums=('6edd982a60ed742306afe69078bd838a9cdfcc1678dee662381224705d0895ba959a5e351886f726cbe32e748ce5553f5c08e8224514460e50fe65d889f194d0') | ||
|
||
package() { | ||
install -d "${pkgdir}/etc/${pkgname}" | ||
install -d "${pkgdir}/usr/bin" | ||
install -d "${pkgdir}/usr/lib/systemd/system" | ||
|
||
install -m755 "${srcdir}/${pkgname}.sh" "${pkgdir}/usr/bin/${pkgname}" | ||
install "${srcdir}/../${pkgname}@.service" "${pkgdir}/usr/lib/systemd/system/${pkgname}@.service" | ||
install "${srcdir}/../${pkgname}@.timer" "${pkgdir}/usr/lib/systemd/system/${pkgname}@.timer" | ||
touch "${pkgdir}/etc/${pkgname}/api-key" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[Unit] | ||
Description=Update the Gandi.net DNS record (%i) | ||
After=local-fs.target | ||
|
||
[Service] | ||
Type=oneshot | ||
ExecStart=/usr/bin/gandi-dns-updater %i | ||
|
||
[Install] | ||
WantedBy=multi-user.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[Unit] | ||
Description=Update the Gandi.net DNS record (%i) periodically | ||
|
||
[Timer] | ||
OnBootSec=5min | ||
OnUnitActiveSec=5min | ||
|
||
[Install] | ||
WantedBy=multi-user.target |