Skip to content

Commit

Permalink
Move to top-level dir
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcusSorealheis committed Dec 6, 2024
1 parent 8671931 commit ebecd78
Show file tree
Hide file tree
Showing 14 changed files with 28 additions and 21 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ jobs:
docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0
with:
context: .
file: ./deployment-examples/docker-compose/Dockerfile
file: ./examples/docker-compose/Dockerfile
build-args: |
OPT_LEVEL=opt
OS_VERSION=${{ matrix.os_version }}
Expand All @@ -142,7 +142,7 @@ jobs:
docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0
with:
context: .
file: ./deployment-examples/docker-compose/Dockerfile
file: ./examples/docker-compose/Dockerfile
build-args: |
OPT_LEVEL=opt
OS_VERSION=${{ matrix.os_version }}
Expand All @@ -153,7 +153,7 @@ jobs:
- name: Compile NativeLink with NativeLink
run: |
mkdir -p ~/.cache && \
cd deployment-examples/docker-compose && \
cd examples/docker-compose && \
(docker-compose up -d || docker compose up -d) && \
cd ../../ && \
docker run --rm --net=host -w /root/nativelink -v $PWD:/root/nativelink trace_machina/nativelink:builder sh -c ' \
Expand Down Expand Up @@ -191,7 +191,7 @@ jobs:
docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0
with:
context: .
file: ./deployment-examples/docker-compose/Dockerfile
file: ./examples/docker-compose/Dockerfile
build-args: |
OPT_LEVEL=fastbuild
OS_VERSION=${{ matrix.os_version }}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ To start, you can deploy NativeLink as a Docker image (as shown below) or by usi

The setups below are **production-grade** installations. See the [contribution docs](https://nativelink.com/docs/contribute/nix/) for instructions on how to build from source with [Bazel](https://nativelink.com/docs/contribute/bazel/), [Cargo](https://nativelink.com/docs/contribute/cargo/), and [Nix](https://nativelink.com/docs/contribute/nix/).

You can find a few example deployments in the [Docs](https://nativelink.com/docs/deployment-examples/kubernetes).
You can find a few example deployments in the [Docs](https://nativelink.com/docs/examples/kubernetes).

### 📦 Prebuilt images

Expand Down
8 changes: 4 additions & 4 deletions deployment-examples/docker-compose/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ bazel test //... \
## Instances

All instances use the same Docker image, `trace_machina/nativelink:latest`,
built from the `Dockerfile` located at `./deployment-examples/docker-compose/Dockerfile`.
built from the `Dockerfile` located at `./examples/docker-compose/Dockerfile`.

### CAS

Expand All @@ -45,7 +45,7 @@ NativeLink system. It's configured in the `docker-compose.yml` file under the
image: trace_machina/nativelink:latest
build:
context: ../..
dockerfile: ./deployment-examples/docker-compose/Dockerfile
dockerfile: ./examples/docker-compose/Dockerfile
network: host
args:
- ADDITIONAL_SETUP_WORKER_CMD=${ADDITIONAL_SETUP_WORKER_CMD:-}
Expand Down Expand Up @@ -78,7 +78,7 @@ the `docker-compose.yml` file under the nativelink_scheduler service.
image: trace_machina/nativelink:latest
build:
context: ../..
dockerfile: ./deployment-examples/docker-compose/Dockerfile
dockerfile: ./examples/docker-compose/Dockerfile
network: host
args:
- ADDITIONAL_SETUP_WORKER_CMD=${ADDITIONAL_SETUP_WORKER_CMD:-}
Expand All @@ -104,7 +104,7 @@ Worker instances are responsible for executing tasks. They're configured in the
image: trace_machina/nativelink:latest
build:
context: ../..
dockerfile: ./deployment-examples/docker-compose/Dockerfile
dockerfile: ./examples/docker-compose/Dockerfile
network: host
args:
- ADDITIONAL_SETUP_WORKER_CMD=${ADDITIONAL_SETUP_WORKER_CMD:-}
Expand Down
6 changes: 3 additions & 3 deletions deployment-examples/docker-compose/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ services:
image: trace_machina/nativelink:latest
build:
context: ../..
dockerfile: ./deployment-examples/docker-compose/Dockerfile
dockerfile: ./examples/docker-compose/Dockerfile
network: host
args:
- ADDITIONAL_SETUP_WORKER_CMD=${ADDITIONAL_SETUP_WORKER_CMD:-}
Expand All @@ -38,7 +38,7 @@ services:
image: trace_machina/nativelink:latest
build:
context: ../..
dockerfile: ./deployment-examples/docker-compose/Dockerfile
dockerfile: ./examples/docker-compose/Dockerfile
network: host
args:
- ADDITIONAL_SETUP_WORKER_CMD=${ADDITIONAL_SETUP_WORKER_CMD:-}
Expand All @@ -57,7 +57,7 @@ services:
image: trace_machina/nativelink:latest
build:
context: ../..
dockerfile: ./deployment-examples/docker-compose/Dockerfile
dockerfile: ./examples/docker-compose/Dockerfile
network: host
args:
- ADDITIONAL_SETUP_WORKER_CMD=${ADDITIONAL_SETUP_WORKER_CMD:-}
Expand Down
7 changes: 7 additions & 0 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Examples

In this directory, we've included a few examples for how to deploy NativeLink for [Chromium](./chromium-example/), [`docker-compose`](./docker-compose/), and [Terraform](./terraform/).

It's important to note that these aren't production deployments. If you are looking to transition to Production, please join the [Slack](https://join.slack.com/t/nativelink/shared_invite/zt-281qk1ho0-krT7HfTUIYfQMdwflRuq7A) where you can ask more questions.

🚀 Happy Coding! 🚀
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions local-remote-execution/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ Let's use NativeLink's Kubernetes example to verify that the setup worked.
## 🚢 Testing with local K8s

Start the cluster and set up NativeLink in an LRE configuration. For details on
this refer to the [Kubernetes example](https://github.com/tracemachina/nativelink/tree/main/deployment-examples/kubernetes):
this refer to the [Kubernetes example](https://github.com/tracemachina/nativelink/tree/main/examples/kubernetes):

> [!TIP]
> NativeLink's `native` CLI tool is self-contained and can be imported into
Expand Down Expand Up @@ -243,8 +243,8 @@ kind: Kustomization
bases:
resources:
- https://github.com/TraceMachina/nativelink//deployment-examples/kubernetes/base
- https://raw.githubusercontent.com/TraceMachina/nativelink/main/deployment-examples/kubernetes/worker-lre-cc.yaml
- https://github.com/TraceMachina/nativelink//examples/kubernetes/base
- https://raw.githubusercontent.com/TraceMachina/nativelink/main/examples/kubernetes/worker-lre-cc.yaml
EOF


Expand Down
2 changes: 1 addition & 1 deletion run_integration_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ if [[ "${#TEST_PATTERNS[@]}" -eq 0 ]]; then
fi

SELF_DIR=$(realpath $(dirname $0))
cd "$SELF_DIR/deployment-examples/docker-compose"
cd "$SELF_DIR/examples/docker-compose"

export UNDER_TEST_RUNNER=1

Expand Down
2 changes: 1 addition & 1 deletion tools/pre-commit-hooks.nix
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ in {
excludes
++ [
# Integration testfiles not intended for production.
"deployment-examples/docker-compose/example-do-not-use-in-prod-key.pem"
"examples/docker-compose/example-do-not-use-in-prod-key.pem"
"kubernetes/components/insecure-certs/example-do-not-use-in-prod-key.pem"
];
enable = true;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ To get started with running NativeLink on-premises, we recommend taking a
look at our example deployments and NativeLink configurations that may suit
your needs.

- [**On-Prem Example Deployments**](/docs/deployment-examples/on-prem-overview):
- [**On-Prem Example Deployments**](/docs/examples/on-prem-overview):
This section provides several examples of deploying NativeLink to an
on-premises Kubernetes setup. These examples aren't intended for production
use, but rather to serve as basic, illustrative guides for using NativeLink
Expand Down
6 changes: 3 additions & 3 deletions web/platform/starlight.conf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,15 @@ export const starlightConfig = {
items: [
{
label: "On-Prem Overview",
link: `${docsRoot}/deployment-examples/on-prem-overview`,
link: `${docsRoot}/examples/on-prem-overview`,
},
{
label: "Kubernetes",
link: `${docsRoot}/deployment-examples/kubernetes`,
link: `${docsRoot}/examples/kubernetes`,
},
{
label: "Chromium",
link: `${docsRoot}/deployment-examples/chromium`,
link: `${docsRoot}/examples/chromium`,
},
],
},
Expand Down

0 comments on commit ebecd78

Please sign in to comment.