Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

do.sh: Add ability to run ovn-heater on Ubuntu #190

Merged
merged 2 commits into from
Dec 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,12 @@ low_scale_task:

install_script:
- 'sed -i "s/<host>/$(hostname)/g" ${PHYS_DEPLOYMENT}'
- ./do.sh install
# test with ubuntu-based ovn-fake-multinode if test runs on Ubuntu image
- 'if [ $(which apt) ]; then
export OS_BASE=ubuntu;
export OS_IMAGE_OVERRIDE=ubuntu:rolling;
fi;
./do.sh install'

pack_caches_script:
- rm -rf runtime-cache/*
Expand Down
4 changes: 4 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,8 @@ COPY $SSH_KEY /root/.ssh/

COPY ovn-fake-multinode-utils/process-monitor.py /tmp/

# This variable is needed on systems where global python's
# environment is marked as "Externally managed" (PEP 668) to allow pip
# installation of "global" packages.
ENV PIP_BREAK_SYSTEM_PACKAGES=1
RUN pip3 install -r /ovn-tester/requirements.txt
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,17 @@ cd ~/ovn-heater
OVS_REPO=https://github.com/dceara/ovs OVS_BRANCH=tmp-branch OVN_REPO=https://github.com/dceara/ovn OVN_BRANCH=tmp-branch-2 ./do.sh install
```

NOTE: Because the installation step is responsible for deploying the ovn-tester
container to the TESTER, this means that if any changes are made to the
ovn-tester application, the installation step must be re-run.
To override base image of ovn-fake-multinode, which is by default
`fedora:latest`, you can use following environment variables:
- OS_BASE
- OS_IMAGE_OVERRIDE

For example, to use latest Ubuntu image you can run:

```
cd ~/ovn-heater
OS_BASE=ubuntu OS_IMAGE_OVERRIDE=ubuntu:rolling ./do.sh install
```

## Perform a reinstallation (e.g., new OVS/OVN versions are needed):

Expand Down
3 changes: 2 additions & 1 deletion do.sh
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ ovn_branch="${OVN_BRANCH:-main}"
ovn_fmn_repo="${OVN_FAKE_MULTINODE_REPO:-https://github.com/ovn-org/ovn-fake-multinode.git}"
ovn_fmn_branch="${OVN_FAKE_MULTINODE_BRANCH:-main}"

OS_BASE="${OS_BASE:-fedora}"
OS_IMAGE_OVERRIDE="${OS_IMAGE_OVERRIDE}"
OS_IMAGE_DEFAULT="registry.fedoraproject.org/fedora:latest"

Expand Down Expand Up @@ -250,7 +251,7 @@ function install_ovn_fake_multinode() {
fi

# Build images locally.
OS_IMAGE=$os_image OVS_SRC_PATH=${rundir}/ovs OVN_SRC_PATH=${rundir}/ovn \
OS_IMAGE=$os_image OS_BASE=${OS_BASE} OVS_SRC_PATH=${rundir}/ovs OVN_SRC_PATH=${rundir}/ovn \
EXTRA_OPTIMIZE=${EXTRA_OPTIMIZE} USE_OVSDB_ETCD=${USE_OVSDB_ETCD} \
RUNC_CMD=podman ./ovn_cluster.sh build
fi
Expand Down
Loading