Commit Graph

11 Commits

Author SHA1 Message Date
Zach Koopmans 4aee370640 Internal change.
PiperOrigin-RevId: 303773475
2020-03-30 10:44:55 -07:00
Zach Koopmans b9210b2855 Fix bm-tools to run on bazel.
Fixes random stuff that is broken on bazel/kokoro.
- random output coming back as "bytes" object instead of str
- missed syntax error in bazel
- a flag is missing in the version of gcloud on kokoro

PiperOrigin-RevId: 301915289
2020-03-19 16:07:05 -07:00
Zach Koopmans 3733499952 Fix master installer.
Sometimes, when we start a new instance, the file
lock on "apt" is locked. Add a loop to the master
installer.

In addition, the "apt-get install" fails to register
runsc in docker, so run the appropriate scripts to
get that to happen.

Also, add some helpful log messages.

PiperOrigin-RevId: 296497357
2020-02-21 13:18:51 -08:00
gVisor bot 3ad6d30563 Call py_requirement with named argument for optional kwarg.
PiperOrigin-RevId: 294930818
2020-02-13 09:21:39 -08:00
Zach Koopmans 16561e461e Add logic to run from baked images.
Change adds the following:
- logic to run from "baked images". See [GVISOR_DIR]/tools/images
- installers which install modified files from a workspace. This
allows users to run benchmarks while modifying runsc.
- removes the --preemptible tag from built GCE instances. Preemptible
instances are much more likely to be preempted on startup, which
manifests for the user as a failed benchmark. I don't currently have
a way to detect if a VM has been preempted that will work for this
change.
https://cloud.google.com/compute/docs/instances/preemptible#preemption_process
https://cloud.google.com/compute/docs/instances/preemptible#preemption_selection

PiperOrigin-RevId: 293697949
2020-02-06 16:02:48 -08:00
Adin Scannell d29e59af9f Standardize on tools directory.
PiperOrigin-RevId: 291745021
2020-01-27 12:21:00 -08:00
Zach Koopmans 94be30a18d Add run-gcp command.
Add command to run benchmarks on GCP backed machines
using the gcloud producer.

Run with:
`bazel run :benchmarks -- run-gcp [BENCHMARK_NAME]`

Tested with the startup benchmark.

PiperOrigin-RevId: 290126444
2020-01-16 13:42:08 -08:00
Zach Koopmans 7b7ce29af3 Update commandline and get local runs working.
PiperOrigin-RevId: 289937063
2020-01-15 14:26:15 -08:00
Zach Koopmans f1b69b159f Implement gcloud_producer for bm-tools
bm-tools works via "Machine" objects, which are front
objects for actual virtual or physical machines. glcoud_producer
produces machines on GCP using the `gcloud` tool.

Included are:
- GCloudProducer - the class producing machines
- MockGCloudProducer - class for mocking GCloudProducer.
- tests using the mock
- test data as .json files. Code to generate this test data may be
included in a follow up.

PiperOrigin-RevId: 289005958
2020-01-09 17:24:35 -08:00
Zach Koopmans e2e3b38460 GCloudProducer: tunnel_dispatch, mock_recorder, and machine.
Work to import GCloudProducer, written in gerrit, which is
too large to do in one CL. GCloudProducer sets up gcloud
instances to run benchmark workloads.

Included are:
- gcloud_mock_recorder - used to Mock GCloudProducer
- tunnel_dispatcher - updates to this module to bring it in line
with the style guide
- machine - updates to this module to bring it in line with the
 style guide

All changes are independent of the rest of the changes, and
should "just build".

PiperOrigin-RevId: 285076423
2019-12-11 15:51:41 -08:00
Zach Koopmans ce32c06843 Import benchmark-tools to main repository.
This has adapted for use with bazel from the original commit
a26e93769ebefd82593a43e22fb13a09717cfa6d.

In particular, the style has been made consistent with internal python style
guidelines, and the packages (including the main entrypoint) have been
refactored in order to allow bazel testing targets.

PiperOrigin-RevId: 283484433
2019-12-02 22:53:26 -08:00