mirror of
https://github.com/avatao-content/test-tutorial-framework
synced 2024-12-05 02:11:32 +00:00
Modify resource's directory structure
This commit is contained in:
parent
11b3ac8eef
commit
9fd3520910
@ -38,7 +38,7 @@ challenge::run() {
|
|||||||
local mount_volumes
|
local mount_volumes
|
||||||
if [[ "${HOTRELOAD:-0}" == "1" ]]; then
|
if [[ "${HOTRELOAD:-0}" == "1" ]]; then
|
||||||
if [[ -d "${BASEIMAGE_PATH}" ]]; then
|
if [[ -d "${BASEIMAGE_PATH}" ]]; then
|
||||||
mount_baseimage="-v ${BASEIMAGE_PATH}/tfw:/usr/local/lib/tfw"
|
mount_baseimage="-e HOTRELOAD=1 -v ${BASEIMAGE_PATH}/tfw:/usr/local/lib/tfw"
|
||||||
fi
|
fi
|
||||||
mount_challenge="-v ${CHALLENGE_PATH}/solvable/src:/.tfw/builtin_event_handlers"
|
mount_challenge="-v ${CHALLENGE_PATH}/solvable/src:/.tfw/builtin_event_handlers"
|
||||||
mount_volumes="${mount_baseimage:-} ${mount_challenge}"
|
mount_volumes="${mount_baseimage:-} ${mount_challenge}"
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
import logging
|
import logging
|
||||||
from sys import stderr
|
|
||||||
from functools import partial
|
from functools import partial
|
||||||
|
|
||||||
from tornado.ioloop import IOLoop
|
from tornado.ioloop import IOLoop
|
||||||
@ -11,8 +10,7 @@ from tfw.components.terminal import TerminalHandler
|
|||||||
from tfw.components.frontend import FrontendProxyHandler, ConsoleLogsHandler
|
from tfw.components.frontend import FrontendProxyHandler, ConsoleLogsHandler
|
||||||
from tfw.components.process_management import ProcessHandler, ProcessLogHandler
|
from tfw.components.process_management import ProcessHandler, ProcessLogHandler
|
||||||
from tfw.components.fsm import FSMHandler
|
from tfw.components.fsm import FSMHandler
|
||||||
from tfw.main import EventHandlerFactory, setup_signal_handlers
|
from tfw.main import EventHandlerFactory, setup_logger, setup_signal_handlers
|
||||||
from tfw.logging import Log, Logger, LogFormatter, VerboseLogFormatter
|
|
||||||
from tfw.config import TFWENV, TAOENV
|
from tfw.config import TFWENV, TAOENV
|
||||||
|
|
||||||
from custom_handlers import CenatorHandler, TestCommandsHandler, messageFSMStepsHandler
|
from custom_handlers import CenatorHandler, TestCommandsHandler, messageFSMStepsHandler
|
||||||
@ -22,10 +20,7 @@ LOG = logging.getLogger(__name__)
|
|||||||
|
|
||||||
def main():
|
def main():
|
||||||
# pylint: disable=unused-variable
|
# pylint: disable=unused-variable
|
||||||
Logger([
|
setup_logger(__file__)
|
||||||
Log(stderr, LogFormatter(20)),
|
|
||||||
Log(TFWENV.LOGFILE, VerboseLogFormatter())
|
|
||||||
]).start()
|
|
||||||
|
|
||||||
eh_factory = EventHandlerFactory()
|
eh_factory = EventHandlerFactory()
|
||||||
# TFW builtin EventHandlers (required for their respective functionalities)
|
# TFW builtin EventHandlers (required for their respective functionalities)
|
||||||
|
@ -1,22 +1,17 @@
|
|||||||
import logging
|
import logging
|
||||||
from sys import stderr
|
|
||||||
|
|
||||||
from tornado.ioloop import IOLoop
|
from tornado.ioloop import IOLoop
|
||||||
|
|
||||||
from tfw.components.pipe_io import PipeIOHandler, ProxyPipeConnectorHandler
|
|
||||||
from tfw.config import TFWENV
|
from tfw.config import TFWENV
|
||||||
from tfw.logging import Log, Logger, LogFormatter, VerboseLogFormatter
|
from tfw.components.pipe_io import PipeIOHandler, ProxyPipeConnectorHandler
|
||||||
from tfw.main import EventHandlerFactory, setup_signal_handlers
|
from tfw.main import EventHandlerFactory, setup_logger, setup_signal_handlers
|
||||||
|
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
# pylint: disable=unused-variable
|
# pylint: disable=unused-variable
|
||||||
Logger([
|
setup_logger(__file__)
|
||||||
Log(stderr, LogFormatter(20)),
|
|
||||||
Log(TFWENV.LOGFILE, VerboseLogFormatter())
|
|
||||||
]).start()
|
|
||||||
|
|
||||||
eh_factory = EventHandlerFactory()
|
eh_factory = EventHandlerFactory()
|
||||||
|
|
||||||
@ -24,7 +19,7 @@ def main():
|
|||||||
'/tmp/tfw_send',
|
'/tmp/tfw_send',
|
||||||
'/tmp/tfw_recv'
|
'/tmp/tfw_recv'
|
||||||
))
|
))
|
||||||
proxy_pipe_eh = eh_factory.build(ProxyPipeConnectorHandler('/tmp/pipes'))
|
proxy_pipe_eh = eh_factory.build(ProxyPipeConnectorHandler(TFWENV.PIPES_DIR))
|
||||||
|
|
||||||
setup_signal_handlers()
|
setup_signal_handlers()
|
||||||
IOLoop.current().start()
|
IOLoop.current().start()
|
||||||
|
Loading…
Reference in New Issue
Block a user