Difference between revisions of "Crontab Manager"

From SME Server
Jump to navigationJump to search
 
(15 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
{{Languages|Crontab_Manager}}
 
{{Languages|Crontab_Manager}}
=Crontab Manager for SME 6.x and above =
+
==About==
Available in the SME8 contribs repository:
+
Crontab Manager will provide a new panel in the Server Manager from which cron tasks can be scheduled.
  
When using it in '''SME 9''', move the '''cronmanager.pm''' file to the appropriate '''perl''' folder.
 
  
==Maintainer==
+
====Maintainers====
[[User:MasterSleepy|Michel Van hees]]<br/>
+
* [[User:MasterSleepy|Michel Van hees]]
 +
* [[User:Apmuthu|Ap.Muthu]]
  
==Description==
 
Cron Manager in the server-manager.
 
  
==Installation==
+
=== Version ===
In SME8
+
{{ #smeversion: smeserver-crontab_manager}}
yum install smeserver-crontab_manager --enablerepo=smecontribs
 
will now install [http://mirror.contribs.org/smeserver/releases/8/smecontribs/i386/RPMS/smeserver-crontab_manager-2.2-1.el5.sme.noarch.rpm smeserver-crontab_manager-2.2-1.el5.sme.noarch.rpm]
 
  
==Uninstallation==
 
  
  rpm -e smeserver-crontab_manager
+
==Installation for SME8 and SME9==
 +
<tabs container><tab name="For SME 10">
 +
  yum install smeserver-crontab_manager --enablerepo=smecontribs
  
==Use==
+
</tab>
You can access Crontab Manager interface in the server-manager and then you can easily create/delete crons.
+
<tab name="For SME 9 and SME 8">
 +
yum install smeserver-crontab_manager --enablerepo=smecontribs
 +
signal-event post-upgrade; signal-event reboot
 +
</tab>
 +
</tabs>
  
After you have made your changes and saved the session the changes will be written to the file /etc/crontab
+
====Useage====
 +
You can access Crontab Manager interface in the server-manager and then you can easily create/delete crons. After you have made your changes and saved the session the changes will be written to the file /etc/crontab
  
On SME versions prior to SME7 to update the crontab file you must issue the following from the command line 
+
==Uninstallation==
expand-template /etc/crontab.
+
  yum remove smeserver-crontab_manager
 
 
==Convert to UTF8==
 
 
 
This contrib was developed with a non utf8 format to convert it safely after installation if you are unable to access to the server-manager panel, as root:
 
 
 
  cd ~
 
  wget http://smeserver.pialasse.com/fichiers/convert_utf-8.sh
 
sh convert_utf-8.sh
 
 
 
The '''convert_utf-8.sh''' file contents are as below:
 
<source lang="bash">
 
#!/bin/bash
 
# Script to convert SME server panel to UTF-8
 
# original author  yythoss walter.thoss@swt-online.de
 
# last auhtor : Jean-Philippe Pialasse aka Unnilennium tests@pialasse.com
 
# licence GPL
 
#
 
#History
 
# 2008-06-07
 
# - added check with iconv to allow to run script as often as you need
 
# - added incremental backup of the locals
 
  
# charset UTF-8
 
to=$(echo "UTF-8" | tr '[[:upper:]]' '[[:lower:]]')
 
  
# function to convert
+
==Bugs==
function code() {
+
Please raise bugs under the SME-Contribs section in [http://bugs.contribs.org/enter_bug.cgi bugzilla]
    count=0
+
and select the smeserver-crontab_manager component or use {{BugzillaFileBug|product=SME%20Contribs|component=smeserver-crontab_manager|title=this link}}.  
    for f in ${files[*]}; do
 
        count=$(( $count + 1))
 
# check if the file is explicitly  declared to be in utf8
 
        type="$(file "$f" | sed 's/^.*:\s\(UTF-8\|ASCII\)\s.*/\1/' | tr '[[:upper:]]' '[[:lower:]]')"
 
# check if the file is in utf8 => return an error if not in UTF8
 
converted="$(iconv -f UTF-8 -t UTF-8 --output=/dev/null $f 2>&1 )"
 
        # if the file is declared to be utf8 do nothing
 
if [ "$type" = "$to" ]; then
 
            echo -n "$count: $f is already $to! => done."
 
    echo
 
# if the file is already in utf8 do nothing   
 
elif [ "$converted" = "" ] ; then
 
    echo -n "$count: $f was already converted using this script $to! => nothing to do."
 
    echo
 
# else you can do the job   
 
        else
 
            case $type in
 
                *iso-8859*)
 
                echo -n "$count: Recode now $f to $to!"
 
echo 
 
                iconv -f "ISO-8859-1" -t "$to" "$f" > "${f}.${to}"
 
                mv "${f}.${to}" "$f"
 
                [[ $? = 0 ]] && echo -n " => done." || echo -n " => failed."
 
                ;;
 
                *ascii*)
 
                echo -n "$count: Recode now $f to $to!"
 
echo 
 
                iconv -f "ascii" -t "$to" "$f" > "${f}.${to}"
 
                mv "${f}.${to}" "$f"
 
                [[ $? = 0 ]] && echo -n " => done." || echo -n " => failed."
 
                ;;
 
                *sgml*)
 
                echo -n "$count: Recode now $f to $to!"
 
echo 
 
                iconv -t "$to" "$f" > "${f}.${to}"
 
                mv "${f}.${to}" "$f"
 
                [[ $? = 0 ]] && echo -n " => done." || echo -n " => failed."
 
                ;;
 
                *)
 
echo -n "Format $type not supported!"
 
;;
 
esac && echo
 
        fi
 
    done
 
}
 
  
#save before running
+
{{#bugzilla:columns=id,product,version,status,summary |sort=id |order=desc |component=smeserver-crontab_manager|noresultsmessage="No open bugs found."}}
number=$(( $(ls -1 locale*.tgz | wc -l) + 1 ))
 
tar czf locale$number.tgz /etc/e-smith/locale/*
 
  
# search for files ine mains languages (we skipped the link)
+
===Changelog===
# why not using this instead : ls -l /etc/e-smith/locale | grep -v '\->'|awk  '{print $9}'|grep -v ^$
+
Only versions released in smecontrib are listed here.
for lang in da de el en-us es fr hu id it nl pt_BR sl sv; do
 
files=$(find "/etc/e-smith/locale/$lang/etc/e-smith/web/functions/" -iname "*" -type f -print)
 
code
 
done
 
  
echo -n "Create the new Server Manager Panel..."
+
{{#smechangelog: smeserver-crontab_manager}}
/etc/e-smith/events/actions/navigation-conf
 
echo
 
  
</source>
 
  
==Additional Info==
 
*[http://www.vanhees.cc/index.php?name=CmodsDownload&file=index&req=viewsdownload&sid=35 MasterSleepy's website]
 
  
 
----
 
----
 
[[Category:Contrib]]
 
[[Category:Contrib]]
 
[[Category:Administration]]
 
[[Category:Administration]]

Latest revision as of 20:26, 9 April 2021


About

Crontab Manager will provide a new panel in the Server Manager from which cron tasks can be scheduled.


Maintainers


Version

Devel 10:
Contrib 10:
Contrib 9:
smeserver-crontab_manager
The latest version of smeserver-crontab_manager is available in the SME repository, click on the version number(s) for more information.



Installation for SME8 and SME9

yum install smeserver-crontab_manager --enablerepo=smecontribs 
yum install smeserver-crontab_manager --enablerepo=smecontribs 
signal-event post-upgrade; signal-event reboot

Useage

You can access Crontab Manager interface in the server-manager and then you can easily create/delete crons. After you have made your changes and saved the session the changes will be written to the file /etc/crontab

Uninstallation

yum remove  smeserver-crontab_manager


Bugs

Please raise bugs under the SME-Contribs section in bugzilla and select the smeserver-crontab_manager component or use this link .

"No open bugs found."

Changelog

Only versions released in smecontrib are listed here.

smeserver-crontab_manager Changelog: SME 10 (smecontribs)
2021/08/21 Terry Fage 2.4.7.sme
- apply locale 2021-08-21 patch

2021/04/09 Jean-Philippe Pialasse 2.4-6.sme
- fix display of double quote in edition [SME: 11028]

prevent use of coma in command line
2021/03/24 Brian Read 2.4-5.sme
- Add Update event to createlinks [SME: 11027]

2020/10/11 Brian Read 2.4-4.sme
- Initial import to SME10 tree [SME: 11027]

- Change link to panel to reference wrapper
2016/03/09 JP Pialasse 2.4-3.sme
- apply locale 2016-03-09 patch