]> SAFE projects GIT repository - jmp/mailleur/commitdiff
adding cron
authorJean-Marc Pigeon (Delson) <jmp@safe.ca>
Thu, 24 Jul 2025 14:12:42 +0000 (10:12 -0400)
committerJean-Marc Pigeon (Delson) <jmp@safe.ca>
Thu, 24 Jul 2025 14:12:42 +0000 (10:12 -0400)
Makefile
Makefile.dist
cron/mailleur.cron [new file with mode: 0644]
support/do_dns_tlsa.sh

index 4efc07013a4099728f725b1cff1651626853a56b..8754f27f048c4e3d4d7a38842a4eb3497b333f39 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -214,8 +214,8 @@ install     :
           @ install -d $(DESTDIR)/$(DATADIR)/$(APPN)/
           @ install -d $(DESTDIR)/$(ETCDIR)/$(APPN)/
           @ install -d $(DESTDIR)/$(ETCDIR)/$(APPN)/dovecot
-          @ install -d $(DESTDIR)/$(ETCDIR)/pki/$(APPN)/
           @ install -d $(DESTDIR)/$(ETCDIR)/sysconfig/
+          @ install -d $(DESTDIR)/$(ETCDIR)/cron.d/
           @ install -d $(DESTDIR)/$(LIBDIR)/$(APPN)/
           @ install -d $(DESTDIR)/$(EXECDIR)/$(APPN)/
           @ install -d $(DESTDIR)/$(SPOOLDIR)/$(APPN)/mails
@@ -228,14 +228,9 @@ install    :
                conf/relayed.conf                       \
                conf/blacklister.conf                   \
                $(DESTDIR)/$(ETCDIR)/$(APPN)
-          @ echo JMPDBG
-          @ ls -ails $(DESTDIR)/$(ETCDIR)/$(APPN)
           @ cp -a                                      \
                conf/dovecot                            \
                $(DESTDIR)/$(ETCDIR)/$(APPN)/
-          @ cp -a                                      \
-               certs/root-safe_CA.pem                  \
-               $(DESTDIR)/$(ETCDIR)/pki/$(APPN)
           @ cp -a                                      \
                linux                                   \
                $(DESTDIR)/$(DATADIR)/$(APPN)/
@@ -246,6 +241,9 @@ install     :
           @ cp -a                                      \
                sysconfig                               \
                $(DESTDIR)/$(ETCDIR)/
+          @ cp -a                                      \
+               cron/$(APPN).cron                       \
+               $(DESTDIR)/$(ETCDIR)/cron.d/
           @ cp -a                                      \
                sql                                     \
                $(DESTDIR)/$(DATADIR)/$(APPN)/
index 2c58bce2b4a49fb346b88aee56cd963b926a4dc8..58708018a33572c381850034ca66ce6c0cc6620b 100644 (file)
@@ -42,9 +42,6 @@ tarfile       : clean
          @ date > $(APLV)/$(APLV).build_date
          @ cp -a Makefile*     $(APLV)/
          @ cp -a app/*.c       $(APLV)/app/
-         @ cp -a                                               \
-               certs/root-safe_CA.pem                          \
-               $(APLV)/certs/
          @ cp -a                                               \
                conf/*.conf                                     \
                conf/dovecot                                    \
@@ -55,6 +52,7 @@ tarfile       : clean
                shell/getsysos.sh                               \
                $(APLV)/shell/
          @ cp -a                                               \
+               cron/                                           \
                tools/                                          \
                $(APLV)/
          @ cp -a support/*.sh                                  \
diff --git a/cron/mailleur.cron b/cron/mailleur.cron
new file mode 100644 (file)
index 0000000..9c47678
--- /dev/null
@@ -0,0 +1,6 @@
+#---------------------------------------------------
+#shell script to manage rpplication ecurring homeworking task
+#---------------------------------------------------
+#to update lets encrypt certificate
+#1 1 1 * * mailleur  PATH=/usr/sbin:$PATH /usr/lib/mailleur/support/do_dns_tlsa.sh
+
index 14a370eeedbcca3a50e97bcd60533d4088f9bc0d..ca9e1d22c3195a9665cf8428c81404a2e825d66d 100755 (executable)
@@ -63,6 +63,7 @@ gen_cert()
 #pass in production mode)
 certbot certonly                                       \
        --apache                                        \
+       --force-renewal                                 \
        --csr ./request.csr                             \
        --fullchain-path ./$APPNAME-fullchain.pem       \
        --chain-path ./$APPNAME-chain.pem               \