Skip to content
This repository has been archived by the owner on Apr 9, 2024. It is now read-only.

Commit

Permalink
Add the oak build config back to use in the README
Browse files Browse the repository at this point in the history
  • Loading branch information
rbehjati committed Sep 13, 2022
1 parent 415f617 commit 89e58e8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,17 @@ in the [`common`](/internal/common/) package.

The [`cmd/builder`](/cmd/builder/) command line tool described above can be used for building the binaries, and at the same time for generating a corresponding provenance file. To use this tool, the developers need to provide a toml file similar to the one in [`testdata/build.toml`](/testdata/build.toml). See the definition of `BuildConfig` in package [`common`](/internal/common/) for thedescription of each field.

To build a binary from the Git repository specified in [`testdata/build.toml`](../testdata/build.toml) and generate its provenance file, run either:
To build a binary from the Git repository specified in [`testdata/oak_build.toml`](../testdata/oak_build.toml) and generate its provenance file, run either:

```bash
$ bazel run //cmd/builder:main -- \
-build_config_path <absolute-path-to-transparent-release-repo>/testdata/build.toml \
-build_config_path <absolute-path-to-transparent-release-repo>/testdata/oak_build.toml \
```

or, alternatively:

```bash
$ go run cmd/builder/main.go -build_config_path testdata/build.toml
$ go run cmd/builder/main.go -build_config_path testdata/oak_build.toml
```

You should see the following output on the console:
Expand All @@ -51,7 +51,7 @@ To build from a local repository you can specify `-git_root_dir`. In this case,

```bash
$ bazel run //cmd/builder:main -- \
-build_config_path <absolute-path-to-transparent-release>/testdata/build.toml \
-build_config_path <absolute-path-to-transparent-release>/testdata/oak_build.toml \
-git_root_dir <path-to-git-repo-root>
```

Expand Down
5 changes: 5 additions & 0 deletions testdata/oak_build.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
repo = "https://github.com/project-oak/oak"
commit_hash = "d11e3de97b8fc1cf49e4ed8001d14d77b98c24b8"
builder_image = "gcr.io/oak-ci/oak@sha256:6e5beabe4ace0e3aaa01ce497f5f1ef30fed7c18c596f35621751176b1ab583d"
command = ["./scripts/xtask", "build-oak-functions-server-variants"]
output_path = "./target/x86_64-unknown-linux-musl/release/oak_functions_loader_base"

0 comments on commit 89e58e8

Please sign in to comment.