mirror of
https://github.com/nolen777/eagle0.git
synced 2026-07-29 00:55:43 +00:00
Enable Shardok cross-compilation with sysroot (#4775)
* Enable Shardok cross-compilation with sysroot - Update sha256 with actual value from sysroot release - Re-enable build-shardok job in docker_build.yml 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> * Add DigitalOcean registry authentication for image push The oci_push rule needs credentials to push to the registry. Creates ~/.docker/config.json with the auth token before pushing. Requires DO_REGISTRY_TOKEN_BASE64 secret to be configured: echo -n "username:token" | base64 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> * Use existing DO_REGISTRY_TOKEN secret for registry auth Base64 encode the token on the fly instead of requiring a separate pre-encoded secret. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> --------- Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -34,26 +34,39 @@ jobs:
|
||||
- name: Build Eagle Docker image
|
||||
run: bazel build //ci:eagle_server_image
|
||||
|
||||
- name: Login to DigitalOcean Container Registry
|
||||
if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.push_images == 'true')
|
||||
env:
|
||||
DO_TOKEN: ${{ secrets.DO_REGISTRY_TOKEN }}
|
||||
run: |
|
||||
mkdir -p ~/.docker
|
||||
AUTH=$(echo -n "${DO_TOKEN}:${DO_TOKEN}" | base64)
|
||||
echo "{\"auths\":{\"registry.digitalocean.com\":{\"auth\":\"${AUTH}\"}}}" > ~/.docker/config.json
|
||||
|
||||
- name: Push Eagle image to DO registry
|
||||
if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.push_images == 'true')
|
||||
run: bazel run //ci:eagle_server_push
|
||||
|
||||
# TODO: Re-enable after sysroot is built and sha256 is updated in MODULE.bazel
|
||||
# 1. Run "Build Linux Sysroot" workflow
|
||||
# 2. Update sha256 in MODULE.bazel with value from release
|
||||
# 3. Uncomment this job
|
||||
#
|
||||
# build-shardok:
|
||||
# runs-on: self-hosted
|
||||
# steps:
|
||||
# - name: Checkout repository
|
||||
# uses: actions/checkout@v4
|
||||
# with:
|
||||
# lfs: false
|
||||
#
|
||||
# - name: Build Shardok Docker image (cross-compile for Linux)
|
||||
# run: bazel build --platforms=//:linux_x86_64 //ci:shardok_server_image
|
||||
#
|
||||
# - name: Push Shardok image to DO registry
|
||||
# if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.push_images == 'true')
|
||||
# run: bazel run --platforms=//:linux_x86_64 //ci:shardok_server_push
|
||||
build-shardok:
|
||||
runs-on: self-hosted
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
lfs: false
|
||||
|
||||
- name: Build Shardok Docker image (cross-compile for Linux)
|
||||
run: bazel build --platforms=//:linux_x86_64 //ci:shardok_server_image
|
||||
|
||||
- name: Login to DigitalOcean Container Registry
|
||||
if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.push_images == 'true')
|
||||
env:
|
||||
DO_TOKEN: ${{ secrets.DO_REGISTRY_TOKEN }}
|
||||
run: |
|
||||
mkdir -p ~/.docker
|
||||
AUTH=$(echo -n "${DO_TOKEN}:${DO_TOKEN}" | base64)
|
||||
echo "{\"auths\":{\"registry.digitalocean.com\":{\"auth\":\"${AUTH}\"}}}" > ~/.docker/config.json
|
||||
|
||||
- name: Push Shardok image to DO registry
|
||||
if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.push_images == 'true')
|
||||
run: bazel run --platforms=//:linux_x86_64 //ci:shardok_server_push
|
||||
|
||||
+1
-2
@@ -72,8 +72,7 @@ use_repo(llvm, "llvm_toolchain", "llvm_toolchain_linux")
|
||||
sysroot = use_repo_rule("@toolchains_llvm//toolchain:sysroot.bzl", "sysroot")
|
||||
sysroot(
|
||||
name = "linux_sysroot",
|
||||
# TODO: Update sha256 after first sysroot build
|
||||
sha256 = "0000000000000000000000000000000000000000000000000000000000000000",
|
||||
sha256 = "3812d376beba78a301eb64dfe2ad01d5896500826054ebb6aa4e00607fa0e347",
|
||||
urls = ["https://github.com/nolen777/eagle0/releases/download/sysroot-noble-v1/ubuntu_noble_amd64_sysroot.tar.xz"],
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user