From 0453a46f668e194d23269510c135a806c7114120 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Mon, 31 Aug 2020 13:04:28 -0700 Subject: [PATCH] ci/bare-metal: Fix capturing of serial output as job artifacts. I tried to put them in the wrong directory -- everything needs to go in results/, which we want clean and ready before we start our job. Part-of: --- .gitlab-ci/bare-metal/cros-servo.sh | 5 +---- .gitlab-ci/bare-metal/cros_servo_run.py | 4 ++-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci/bare-metal/cros-servo.sh b/.gitlab-ci/bare-metal/cros-servo.sh index 6de59d9..b05eaec 100755 --- a/.gitlab-ci/bare-metal/cros-servo.sh +++ b/.gitlab-ci/bare-metal/cros-servo.sh @@ -50,7 +50,6 @@ set -ex # Clear out any previous run's artifacts. rm -rf results/ mkdir -p results -find artifacts/ -name serial\*.txt | xargs rm -f # Create the rootfs in the NFS directory. rm to make sure it's in a pristine # state, since it's volume-mounted on the host. @@ -72,9 +71,7 @@ ret=$? set -e # Bring artifacts back from the NFS dir to the build dir where gitlab-runner -# will look for them. Note that results/ may already exist, so be careful -# with cp. -mkdir -p results +# will look for them. cp -Rp /nfs/results/. results/ exit $ret diff --git a/.gitlab-ci/bare-metal/cros_servo_run.py b/.gitlab-ci/bare-metal/cros_servo_run.py index b53763b..6d7f601 100755 --- a/.gitlab-ci/bare-metal/cros_servo_run.py +++ b/.gitlab-ci/bare-metal/cros_servo_run.py @@ -35,8 +35,8 @@ class CrosServoRun: self.sentinel = object() self.threads_done = 0 - self.ec_ser = SerialBuffer(ec, "artifacts/serial-ec.txt", "R SERIAL-EC> ") - self.cpu_ser = SerialBuffer(cpu, "artifacts/serial.txt", "R SERIAL-CPU> ") + self.ec_ser = SerialBuffer(ec, "results/serial-ec.txt", "R SERIAL-EC> ") + self.cpu_ser = SerialBuffer(cpu, "results/serial.txt", "R SERIAL-CPU> ") self.iter_feed_ec = threading.Thread(target=self.iter_feed_queue, daemon=True, args=(self.ec_ser.lines(),)) self.iter_feed_ec.start() -- 2.7.4