5 Commits

Author SHA1 Message Date
Ruslan Aliev
d1abe6e1ea Decouple implementations and unit tests in container module
Unit test should follow black-box approach.

Change-Id: I98c46c613a73b539f79d8dfe99cd73592792536d
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Closes: #561
2021-07-16 21:02:03 -05:00
Kostiantyn Kalynovskyi
7c9dd85eeb Fix docker stdin write.
Without this commit airship can hang endlessly waiting for stdin
to be open. Apparently it depends on the containerd and docker
server version. This commit adds asnyc writing to stdin, this way
we don't have to wait for write to complete before starting docker
container. The code uses similar approach to upstream docker cli
implementation.

Related-To: #513

Change-Id: I2e6d4cbe37df1f8cba356af79c1c2cf18438e86c
2021-04-07 14:37:17 +00:00
Ruslan Aliev
92ce88fc29 Allow relative and ~ path for container mount
This patch allow to specify relative and home (~/) path for container
mounts.src field. In case if specified path is not absolute, it will be
created by following pattern: 'targetPath+mounts.src'; in case if path
contains ~/ - it will be properly expanded (it will allow us to mount
~/.airship working directory).

Change-Id: I878094371a2bc4e48216b1d076e466e3d29a86f6
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #484
Closes: #484
2021-03-25 16:41:30 -05:00
Kostiantyn Kalynovskyi
769e164b59 Implement airship container type
This will enable airship to run containers in privileged mode
as well and to specify commands to be executed.

Change-Id: I663eb55547bb821f26a9071c24d08166a3b3d56b
2021-02-08 17:59:11 +00:00
Kostiantyn Kalynovskyi
d78cbe96a1 Extend Generic Container interface
This also moves KRM related logic from executors package to
container package, and creates ClientV1Alpha1 interface that
would allow us to have versioned clients for generic container
executor.

Change-Id: I4b32fd8dd089b9ccea2ed64a805702e6a8705706
2021-02-08 15:50:20 +00:00