mirror of
https://github.com/Doodle3D/doodle3d-firmware.git
synced 2024-12-22 11:03:48 +01:00
Install loglite filter to wifibox.
Small fixes to loglite filter. Set dummy host/port/agent info on command-line API call. Remove non-functional version info from shell banner. New todo item in release script. Conflicts: extra/scripts/publish-wifibox-release.lua
This commit is contained in:
parent
52c9435534
commit
759c0a3007
4
Makefile
4
Makefile
@ -88,6 +88,7 @@ define Package/wifibox/install
|
|||||||
#$(INSTALL_DIR) $(1)/etc
|
#$(INSTALL_DIR) $(1)/etc
|
||||||
$(INSTALL_DIR) $(1)/etc/init.d
|
$(INSTALL_DIR) $(1)/etc/init.d
|
||||||
$(INSTALL_DIR) $(1)/etc/config
|
$(INSTALL_DIR) $(1)/etc/config
|
||||||
|
$(INSTALL_DIR) $(1)/root/
|
||||||
#$(INSTALL_DIR) $(1)/www
|
#$(INSTALL_DIR) $(1)/www
|
||||||
$(INSTALL_DIR) $(1)/www/cgi-bin
|
$(INSTALL_DIR) $(1)/www/cgi-bin
|
||||||
|
|
||||||
@ -102,6 +103,9 @@ define Package/wifibox/install
|
|||||||
|
|
||||||
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/d3d-updater.lua $(1)/$(TGT_LUA_DIR_SUFFIX)/script
|
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/d3d-updater.lua $(1)/$(TGT_LUA_DIR_SUFFIX)/script
|
||||||
$(LN) -s /$(TGT_LUA_DIR_SUFFIX)/script/d3d-updater.lua $(1)/bin/d3d-updater
|
$(LN) -s /$(TGT_LUA_DIR_SUFFIX)/script/d3d-updater.lua $(1)/bin/d3d-updater
|
||||||
|
$(CP) $(WIFIBOX_BASE_DIR)/script/loglite-filters.lua $(1)/root/
|
||||||
|
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/loglite.lua $(1)/$(TGT_LUA_DIR_SUFFIX)/script
|
||||||
|
$(LN) -s /$(TGT_LUA_DIR_SUFFIX)/script/loglite.lua $(1)/bin/loglite
|
||||||
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/wifibox_init $(1)/etc/init.d/wifibox
|
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/wifibox_init $(1)/etc/init.d/wifibox
|
||||||
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/dhcpcheck_init $(1)/etc/init.d/dhcpcheck
|
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/dhcpcheck_init $(1)/etc/init.d/dhcpcheck
|
||||||
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/d3dapi $(1)/$(TGT_LUA_DIR_SUFFIX)/script
|
$(INSTALL_BIN) $(WIFIBOX_BASE_DIR)/script/d3dapi $(1)/$(TGT_LUA_DIR_SUFFIX)/script
|
||||||
|
@ -27,8 +27,8 @@
|
|||||||
-- HostName ftp.greenhost.nl
|
-- HostName ftp.greenhost.nl
|
||||||
-- Some basic sanity checks are built in (unique version, updated release notes, 'clean' openwrt config)
|
-- Some basic sanity checks are built in (unique version, updated release notes, 'clean' openwrt config)
|
||||||
-- but lots others are still missing (mainly: clean git repo's, freshly built images).
|
-- but lots others are still missing (mainly: clean git repo's, freshly built images).
|
||||||
-- The script must be run from within the openwrt build root. So it's handy to create a symlink
|
-- The script must be run from within the openwrt build root. So it's handy to create a symlink
|
||||||
-- to this file. You could to something like from the build root:
|
-- to this file. You could to something like from the build root:
|
||||||
-- ln -s ~/wrt-wifibox-feed/doodle3d-firmware/extra/scripts/publish-wifibox-release.lua .
|
-- ln -s ~/wrt-wifibox-feed/doodle3d-firmware/extra/scripts/publish-wifibox-release.lua .
|
||||||
-- Then you can start with:
|
-- Then you can start with:
|
||||||
-- cd trunk ../publish-wifibox-release.lua
|
-- cd trunk ../publish-wifibox-release.lua
|
||||||
|
@ -38,7 +38,7 @@ if [ ! -f $IPKG_INSTROOT/etc/banner.default ]; then
|
|||||||
mv $IPKG_INSTROOT/etc/banner $IPKG_INSTROOT/etc/banner.default
|
mv $IPKG_INSTROOT/etc/banner $IPKG_INSTROOT/etc/banner.default
|
||||||
cat <<-'EOM' > $IPKG_INSTROOT/etc/banner
|
cat <<-'EOM' > $IPKG_INSTROOT/etc/banner
|
||||||
........D o o d l e 3 D
|
........D o o d l e 3 D
|
||||||
.......________ _____ _____ v \$(PACKAGE_VERSION)
|
.......________ _____ _____
|
||||||
....../ / / |__ / __/ / - /___ __
|
....../ / / |__ / __/ / - /___ __
|
||||||
...../ / / /--// _|-// --| . /v /
|
...../ / / /--// _|-// --| . /v /
|
||||||
..../________/__//__/__//____/___/_^_\
|
..../________/__//__/__//____/___/_^_\
|
||||||
|
@ -181,6 +181,10 @@ function M.new(environment, postData, debugEnabled)
|
|||||||
self.remoteAddress = environment['REMOTE_ADDR']
|
self.remoteAddress = environment['REMOTE_ADDR']
|
||||||
else
|
else
|
||||||
self.requestMethod = 'CMDLINE'
|
self.requestMethod = 'CMDLINE'
|
||||||
|
self.remoteHost = "cmdline"
|
||||||
|
self.remotePort = "0"
|
||||||
|
self.userAgent = "shell"
|
||||||
|
self.remoteAddress = "0.0.0.0"
|
||||||
end
|
end
|
||||||
|
|
||||||
self.cmdLineArgs = kvTableFromArray(arg)
|
self.cmdLineArgs = kvTableFromArray(arg)
|
||||||
|
@ -10,7 +10,7 @@ M.printstart = {
|
|||||||
M.test = {
|
M.test = {
|
||||||
['options'] = { 'delete_mode' },
|
['options'] = { 'delete_mode' },
|
||||||
['patterns'] = {
|
['patterns'] = {
|
||||||
['(verbose)'] = 'underline,cyan,_delete'
|
['(verbose)'] = 'underline,cyan,_delete',
|
||||||
['(info)'] = 'magenta',
|
['(info)'] = 'magenta',
|
||||||
['ABSD'] = '_nodelete',
|
['ABSD'] = '_nodelete',
|
||||||
['SE?RV?'] = 'bblue'
|
['SE?RV?'] = 'bblue'
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
#!/usr/bin/env lua
|
||||||
|
|
||||||
-- Notes
|
-- Notes
|
||||||
-- * directives: either a color, a color prefixed by 'b' or one of: _delete, _nodelete, [_matchonly]
|
-- * directives: either a color, a color prefixed by 'b' or one of: _delete, _nodelete, [_matchonly]
|
||||||
-- * pattern rules are matched top to bottom, the last one encountered overriding any previous conflicting directive
|
-- * pattern rules are matched top to bottom, the last one encountered overriding any previous conflicting directive
|
||||||
@ -50,9 +52,9 @@ local DFL_FILTERSET_FILE = "loglite-filters.lua"
|
|||||||
local DEFAULT_FILTERSET = {
|
local DEFAULT_FILTERSET = {
|
||||||
['options'] = { 'default_enabled', 'keep_mode' },
|
['options'] = { 'default_enabled', 'keep_mode' },
|
||||||
['patterns'] = {
|
['patterns'] = {
|
||||||
['(error)'] = 'red',
|
['%(error%)'] = 'red',
|
||||||
['(warning)'] = 'yellow',
|
['%(warning%)'] = 'yellow',
|
||||||
['(bulk)'] = 'gray'
|
['%(bulk%)'] = 'gray'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -174,7 +176,7 @@ local function main()
|
|||||||
local tailin = followFile and io.popen('tail -f ' .. followFile, 'r') or io.stdin
|
local tailin = followFile and io.popen('tail -f ' .. followFile, 'r') or io.stdin
|
||||||
|
|
||||||
local patterns = DEFAULT_FILTERSET.patterns
|
local patterns = DEFAULT_FILTERSET.patterns
|
||||||
local options = { ['mode'] = 'keep', count = 'all' }
|
local options = { ['mode'] = 'keep', count = 'none' }
|
||||||
|
|
||||||
pcall(tailStream, tailin, patterns, options) -- Note: protected call to suppress interrupt error thrown by lines iterator
|
pcall(tailStream, tailin, patterns, options) -- Note: protected call to suppress interrupt error thrown by lines iterator
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user