Skip to content

Commit 3110939

Browse files
avtikhonTotktonada
authored andcommitted
Move .tarantoolctl config to test-run repository
Moved .tarantoolctl to test-run tool submodule repository as: <tarantool repository>/test-run/.tarantoolctl Also set backward compability to use old path location: <tarantool repository>/test/.tarantoolctl as its primary place. Needed for tarantool/tarantool#5504 Part of #78
1 parent d27f264 commit 3110939

File tree

2 files changed

+24
-1
lines changed

2 files changed

+24
-1
lines changed

.tarantoolctl

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
-- Options for test-run tarantoolctl
2+
3+
local workdir = os.getenv('TEST_WORKDIR')
4+
default_cfg = {
5+
pid_file = workdir,
6+
wal_dir = workdir,
7+
memtx_dir = workdir,
8+
vinyl_dir = workdir,
9+
log = workdir,
10+
background = false,
11+
}
12+
13+
instance_dir = workdir
14+
15+
-- vim: set ft=lua :

lib/tarantool_server.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -776,7 +776,15 @@ def copy_files(self):
776776
if (e.errno == errno.ENOENT):
777777
continue
778778
raise
779-
shutil.copy('.tarantoolctl', self.vardir)
779+
# Previously tarantoolctl configuration file located in tarantool
780+
# repository at test/ directory. Currently it is located in root
781+
# path of test-run/ submodule repository. For backward compatibility
782+
# this file should be checked at the old place and only after at
783+
# the current.
784+
tntctl_file = '.tarantoolctl'
785+
if not os.path.exists(tntctl_file):
786+
tntctl_file = os.path.join(self.TEST_RUN_DIR, '.tarantoolctl')
787+
shutil.copy(tntctl_file, self.vardir)
780788
shutil.copy(os.path.join(self.TEST_RUN_DIR, 'test_run.lua'),
781789
self.vardir)
782790
# Need to use get here because of nondefault servers doesn't have ini.

0 commit comments

Comments
 (0)