Docker to set up all the containers for
Postgres, Paddles, Pulpito, Beanstalk, and Teuthology.
-Currently, there are two modes of execution:
+Currently, it's possible to execute against two classes of test nodes:
* Using containerized test nodes
* Advantage: No need for a lab at all!
* Advantage: Can run all Ceph tests
* Disadvantage: Requires lab access
-In both cases, the teuthology container will be built with code from the repository clone that's currently in use.
+
+Additionally, there are two modes of execution:
+* One-shot (the default): Containers start up, schedule and run the `teuthology:no-ceph` suite, and shut down. Success or failure is indicated by the `start.sh` exit code.
+* Wait: Containers start up, and `teuthology-dispatcher` is started, but no jobs are scheduled. Runs until the user presses Ctrl-C or `docker-compose down` is run.
+
+The teuthology container will be built with code from the repository clone that's currently in use.
## Prerequisites
## Running Tests
-When you are ready to run tests:
+To run the default `teuthology:no-ceph` suite in one-shot mode:
```bash
./start.sh
+```
+
+To run in wait mode:
+```bash
+TEUTHOLOGY_WAIT=1 ./start.sh
+```
+
+To schedule tests in wait mode:
+```bash
+docker exec docker-compose_teuthology_1 /venv/bin/teuthology-suite ...
```
\ No newline at end of file
SSH_PRIVKEY_FILE:
MACHINE_TYPE:
TESTNODES:
+ TEUTHOLOGY_WAIT:
testnode:
build:
context: ./testnode
export SSH_PRIVKEY_FILE=$(basename $SSH_PRIVKEY_PATH | cut -d. -f1)
fi
+if [ -z "$TEUTHOLOGY_WAIT" ]; then
+ DC_EXIT_FLAG='--abort-on-container-exit --exit-code-from teuthology'
+ DC_AUTO_DOWN_CMD='docker-compose down'
+fi
+export TEUTHOLOGY_WAIT
+
set +e
trap "docker-compose down" SIGINT
docker-compose up \
--build \
- --abort-on-container-exit \
- --exit-code-from teuthology
-docker-compose down
\ No newline at end of file
+ $DC_EXIT_FLAG
+$DC_AUTO_DOWN_CMD
\ No newline at end of file
CUSTOM_CONF=/teuthology/containerized_node.yaml
fi
export MACHINE_TYPE=${MACHINE_TYPE:-testnode}
-teuthology-suite -v \
- --teuthology-branch $TEUTHOLOGY_BRANCH \
- --ceph-repo https://github.com/ceph/ceph.git \
- --suite-repo https://github.com/ceph/ceph.git \
- -c master \
- -m $MACHINE_TYPE \
- --limit 1 \
- -n 100 \
- --suite teuthology:no-ceph \
- --filter-out "libcephfs,kclient,stream,centos,rhel" \
- -d ubuntu -D 20.04 \
- --suite-branch master \
- --subset 9000/100000 \
- -p 75 \
- --seed 349 \
- --force-priority \
- $CUSTOM_CONF
+if [ -z "$TEUTHOLOGY_WAIT" ]; then
+ teuthology-suite -v \
+ --teuthology-branch $TEUTHOLOGY_BRANCH \
+ --ceph-repo https://github.com/ceph/ceph.git \
+ --suite-repo https://github.com/ceph/ceph.git \
+ -c master \
+ -m $MACHINE_TYPE \
+ --limit 1 \
+ -n 100 \
+ --suite teuthology:no-ceph \
+ --filter-out "libcephfs,kclient,stream,centos,rhel" \
+ -d ubuntu -D 20.04 \
+ --suite-branch master \
+ --subset 9000/100000 \
+ -p 75 \
+ --seed 349 \
+ --force-priority \
+ $CUSTOM_CONF
+ DISPATCHER_EXIT_FLAG='--exit-on-empty-queue'
+fi
teuthology-dispatcher -v \
--log-dir /teuthology/log \
--tube $MACHINE_TYPE \
- --exit-on-empty-queue
\ No newline at end of file
+ $DISPATCHER_EXIT_FLAG
\ No newline at end of file