Help:Extension/ScriptFunctions
From Metabolomics.JP
(Difference between revisions)
Line 34: | Line 34: | ||
<pre>require_once( "$IP/ScritFunctions.php" ); | <pre>require_once( "$IP/ScritFunctions.php" ); | ||
$ugLuaPath = "path to directory which in lua binary"; | $ugLuaPath = "path to directory which in lua binary"; | ||
− | $ugTmpPath = "path to tmp directory"; ( default: /tmp )</pre> | + | $ugTmpPath = "path to tmp directory"; ( default: "/tmp" )</pre> |
$ugLuaPathを定義しなかった場合、プログラムは実行されません。<br> | $ugLuaPathを定義しなかった場合、プログラムは実行されません。<br> | ||
$ugTmpPathはluaプログラムを一時的に保存する場所です。</li> | $ugTmpPathはluaプログラムを一時的に保存する場所です。</li> |
Revision as of 15:50, 11 September 2008
Extension Information | |
Implementation | |
Description | |
Author(s) | K, Suwa |
Version | 0.1 |
MediaWiki | 1.11.1 |
License | |
Hooks used | |
Token type | |
Contents |
外部スクリプトを使えるようにするextensionです。
現在使えるのはluaのみです。
luaが無限ループに陥った場合などの対処として、script_monitoring.shをcrondで実行し、10秒以上実行されているluaプログラムを停止(kill)します。
Requirements
Download
version | source | size |
0.1(September 11,2008) | ScriptFunctions.phps |
version | source | size |
0.1(September 11,2008) | script_monitoring.sh |
Installtion
- Download source and rename to ScriptFunctions.php and script_monitoring.sh.
- Put in extensions/ directory.
- Insert follow line to LocalSettings.php
require_once( "$IP/ScritFunctions.php" ); $ugLuaPath = "path to directory which in lua binary"; $ugTmpPath = "path to tmp directory"; ( default: "/tmp" )
$ugLuaPathを定義しなかった場合、プログラムは実行されません。
$ugTmpPathはluaプログラムを一時的に保存する場所です。
- Put in any direcotry.( ideal: /etc/cron.d/ )
- Insert follow line to /etc/crontab
* * * * * root /etc/cron.d/lua_monitoring.sh