-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Build Wolfi images #47182
Merged
Merged
Build Wolfi images #47182
Changes from all commits
Commits
Show all changes
58 commits
Select commit
Hold shift + click to select a range
49e572d
Add initial buildWolfiDockerImage implementation
willdollman 1874e05
Add ops set for building wolfi images
willdollman 77a7275
Build wolfi images on branches and tweak package/base logic
willdollman 7c088d9
Build candidate wolfi image
willdollman d22c18a
Add wolfi-specific build scripts for gitserver
willdollman 2146757
Move Wolfi build files from cmd/ to enterprise/cmd
willdollman b0012fe
Re-enable wolfi docker push
willdollman 9c75a06
Add wolfi builds for frontend
willdollman 818f95e
Add github-proxy wolfi build
willdollman 16b0d48
Add loadtest wolfi build
willdollman 44e1149
Add migrator build
willdollman ccf1cb0
Update wolfi base image location
willdollman ede1c66
Add wolfi builds for OSS frontend and gitserver
willdollman bf8afa8
Add enterprise/migrator build script
willdollman 217df1a
Add wolfi builds for repo-updater
willdollman 1d51b94
Add wolfi builds for searcher
willdollman 1862fa6
Add wolfi builds for symbols
willdollman 880f6b9
Build additional full images
willdollman fd4fafb
Add wolfi builds for batcheshelper
willdollman a1028a1
Add wolfi build for precise code intel
willdollman d17877c
Add wolfi build for enterprise worker
willdollman 26af851
Fix wolfi base image for precise code intel
willdollman c81407c
Always build x86_64 Wolfi images
willdollman 0a2cc44
Build symbols again
willdollman 285fae4
Try using non-Alpine golang container for symbols build
willdollman 2c9f4a3
Revert to alpine golang build env
willdollman fd8ee3d
Build full wolfi images on the bazel queue
willdollman 3be6b3e
Disable building symbols and bazel runner for now
willdollman f687b20
Tweak local-build scripts
willdollman ce0fc9e
Add rough initial versions of server wolfi builds
willdollman 8db3b56
Try building images with bazel agent again
willdollman f099623
Actually use bazel for gitserver builds
willdollman fdcc1a5
Build symbols in chainguard:go
willdollman 33e275b
Build all Go binaries for Wolfi with Bazel
willdollman 1e403d9
Add wolfi build scripts for embeddings image
willdollman 157a7bd
Rough initial version of the server image
willdollman c37af38
Specify platform for symbols go-build
willdollman a31e23a
Build 3rd party Wolfi images (#47368)
willdollman 4fedb1d
Add bind-tools to all base images
willdollman 5754459
Make docker build commands more consistent
willdollman 53b494a
Add wolfi build scripts for llm-proxy
willdollman 4425f4d
Add wolfi build scripts for executor-kubernetes
willdollman 5662a68
Update build-wolfi.sh scripts to match latest build.sh scripts
willdollman 1771885
shellfmt build.sh scripts
willdollman 1ed2df9
Set up proper deps for wolfi images and base images
willdollman 4ab2586
Add buildAllBaseImages no-op command
willdollman 095023a
Use stepKeys in wolfi base image dependencies
willdollman cb080df
Sanitize stepKeys
willdollman 30a478d
Remove some completed TODOs
willdollman d8ece3f
Remove images from wolfi pipeline
willdollman 0985a7c
Regenerate CI reference
willdollman 110688a
Remove symbols build flag
willdollman 2a89c24
Add hadolint ignores to use of latest with Wolfi images
willdollman 55e5cb8
Fix CMD formatting
willdollman c1ebf0b
Fix symbols go-build script
willdollman 681b821
Merge branch 'main' into wolfi/build-wolfi
willdollman 7878dad
Specify exact Wolfi images to build
willdollman b4e44bb
sg generate
willdollman File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Dockerfile for Wolfi-based images | ||
# This is currently being tested in parallel to Alpine - you don't need to update this | ||
# file if you change the regular Dockerfile. | ||
|
||
# hadolint ignore=DL3007 | ||
FROM us.gcr.io/sourcegraph-dev/wolfi-sourcegraph-base:latest | ||
|
||
ARG COMMIT_SHA="unknown" | ||
ARG DATE="unknown" | ||
ARG VERSION="unknown" | ||
|
||
LABEL org.opencontainers.image.revision=${COMMIT_SHA} | ||
LABEL org.opencontainers.image.created=${DATE} | ||
LABEL org.opencontainers.image.version=${VERSION} | ||
LABEL com.sourcegraph.github.url=https://github.com/sourcegraph/sourcegraph/commit/${COMMIT_SHA} | ||
|
||
ENV CONFIGURATION_MODE=server PGDATABASE=sg PGHOST=pgsql PGPORT=5432 PGSSLMODE=disable PGUSER=sg CODEINTEL_PGDATABASE=sg CODEINTEL_PGHOST=codeintel-db CODEINTEL_PGPORT=5432 CODEINTEL_PGSSLMODE=disable CODEINTEL_PGUSER=sg PUBLIC_REPO_REDIRECTS=true | ||
USER sourcegraph | ||
|
||
CMD ["serve"] | ||
ENTRYPOINT ["/sbin/tini", "--", "/usr/local/bin/frontend"] | ||
COPY frontend /usr/local/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#!/usr/bin/env bash | ||
|
||
# We want to build multiple go binaries, so we use a custom build step on CI. | ||
cd "$(dirname "${BASH_SOURCE[0]}")"/../.. | ||
set -ex | ||
|
||
OUTPUT=$(mktemp -d -t sgdockerbuild_XXXXXXX) | ||
cleanup() { | ||
rm -rf "$OUTPUT" | ||
} | ||
trap cleanup EXIT | ||
|
||
# Environment for building linux binaries | ||
export GO111MODULE=on | ||
export GOARCH=amd64 | ||
export GOOS=linux | ||
export CGO_ENABLED=0 | ||
|
||
echo "--- go build" | ||
pkg="github.com/sourcegraph/sourcegraph/cmd/frontend" | ||
go build -trimpath -ldflags "-X github.com/sourcegraph/sourcegraph/internal/version.version=$VERSION -X github.com/sourcegraph/sourcegraph/internal/version.timestamp=$(date +%s)" -buildmode exe -tags dist -o "$OUTPUT/$(basename $pkg)" "$pkg" | ||
|
||
echo "--- docker build $IMAGE" | ||
docker build -f cmd/frontend/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Dockerfile for Wolfi-based images | ||
# This is currently being tested in parallel to Alpine - you don't need to update this | ||
# file if you change the regular Dockerfile. | ||
|
||
# hadolint ignore=DL3007 | ||
FROM us.gcr.io/sourcegraph-dev/wolfi-sourcegraph-base:latest | ||
|
||
ARG COMMIT_SHA="unknown" | ||
ARG DATE="unknown" | ||
ARG VERSION="unknown" | ||
|
||
LABEL org.opencontainers.image.revision=${COMMIT_SHA} | ||
LABEL org.opencontainers.image.created=${DATE} | ||
LABEL org.opencontainers.image.version=${VERSION} | ||
LABEL com.sourcegraph.github.url=https://github.com/sourcegraph/sourcegraph/commit/${COMMIT_SHA} | ||
|
||
ENV LOG_REQUEST=true | ||
USER sourcegraph | ||
|
||
ENTRYPOINT ["/sbin/tini", "--", "/usr/local/bin/github-proxy"] | ||
COPY github-proxy /usr/local/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/usr/bin/env bash | ||
|
||
# We want to build multiple go binaries, so we use a custom build step on CI. | ||
cd "$(dirname "${BASH_SOURCE[0]}")"/../.. | ||
set -ex | ||
|
||
OUTPUT=$(mktemp -d -t sgdockerbuild_XXXXXXX) | ||
cleanup() { | ||
rm -rf "$OUTPUT" | ||
} | ||
trap cleanup EXIT | ||
|
||
if [[ "${DOCKER_BAZEL:-false}" == "true" ]]; then | ||
|
||
bazel build //cmd/github-proxy \ | ||
--stamp \ | ||
--workspace_status_command=./dev/bazel_stamp_vars.sh \ | ||
--platforms=@io_bazel_rules_go//go/toolchain:linux_amd64 | ||
|
||
out=$(bazel cquery //cmd/github-proxy --output=files) | ||
cp "$out" "$OUTPUT" | ||
|
||
docker build -f cmd/github-proxy/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION | ||
exit $? | ||
fi | ||
|
||
# Environment for building linux binaries | ||
export GO111MODULE=on | ||
export GOARCH=amd64 | ||
export GOOS=linux | ||
export CGO_ENABLED=0 | ||
|
||
pkg="github.com/sourcegraph/sourcegraph/cmd/github-proxy" | ||
go build -trimpath -ldflags "-X github.com/sourcegraph/sourcegraph/internal/version.version=$VERSION -X github.com/sourcegraph/sourcegraph/internal/version.timestamp=$(date +%s)" -buildmode exe -tags dist -o "$OUTPUT/$(basename $pkg)" "$pkg" | ||
|
||
docker build -f cmd/github-proxy/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Dockerfile for Wolfi-based images | ||
# This is currently being tested in parallel to Alpine - you don't need to update this | ||
# file if you change the regular Dockerfile. | ||
|
||
# hadolint ignore=DL3007 | ||
FROM us.gcr.io/sourcegraph-dev/wolfi-gitserver-base:latest | ||
|
||
ARG COMMIT_SHA="unknown" | ||
ARG DATE="unknown" | ||
ARG VERSION="unknown" | ||
|
||
LABEL org.opencontainers.image.revision=${COMMIT_SHA} | ||
LABEL org.opencontainers.image.created=${DATE} | ||
LABEL org.opencontainers.image.version=${VERSION} | ||
LABEL com.sourcegraph.github.url=https://github.com/sourcegraph/sourcegraph/commit/${COMMIT_SHA} | ||
|
||
RUN mkdir -p /data/repos && chown -R sourcegraph:sourcegraph /data/repos | ||
USER sourcegraph | ||
|
||
WORKDIR / | ||
|
||
ENTRYPOINT ["/sbin/tini", "--", "/usr/local/bin/gitserver"] | ||
COPY gitserver /usr/local/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
#!/usr/bin/env bash | ||
|
||
# We want to build multiple go binaries, so we use a custom build step on CI. | ||
cd "$(dirname "${BASH_SOURCE[0]}")"/../.. | ||
set -ex | ||
|
||
OUTPUT=$(mktemp -d -t sgdockerbuild_XXXXXXX) | ||
|
||
cleanup() { | ||
rm -rf "$OUTPUT" | ||
} | ||
|
||
trap cleanup EXIT | ||
|
||
if [[ "${DOCKER_BAZEL:-false}" == "true" ]]; then | ||
bazel build //cmd/gitserver \ | ||
--stamp \ | ||
--workspace_status_command=./dev/bazel_stamp_vars.sh \ | ||
--platforms=@io_bazel_rules_go//go/toolchain:linux_amd64 | ||
|
||
out=$(bazel cquery //cmd/gitserver --output=files) | ||
cp "$out" "$OUTPUT" | ||
|
||
docker build -f cmd/gitserver/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION | ||
exit $? | ||
fi | ||
|
||
# Environment for building linux binaries | ||
export GO111MODULE=on | ||
export GOARCH=amd64 | ||
export GOOS=linux | ||
export CGO_ENABLED=0 | ||
|
||
pkg="github.com/sourcegraph/sourcegraph/cmd/gitserver" | ||
go build -trimpath -ldflags "-X github.com/sourcegraph/sourcegraph/internal/version.version=$VERSION -X github.com/sourcegraph/sourcegraph/internal/version.timestamp=$(date +%s)" -buildmode exe -tags dist -o "$OUTPUT/$(basename $pkg)" "$pkg" | ||
|
||
docker build -f cmd/gitserver/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Dockerfile for Wolfi-based images | ||
# This is currently being tested in parallel to Alpine - you don't need to update this | ||
# file if you change the regular Dockerfile. | ||
|
||
# hadolint ignore=DL3007 | ||
FROM us.gcr.io/sourcegraph-dev/wolfi-sourcegraph-base:latest | ||
|
||
ARG COMMIT_SHA="unknown" | ||
ARG DATE="unknown" | ||
ARG VERSION="unknown" | ||
|
||
LABEL org.opencontainers.image.revision=${COMMIT_SHA} | ||
LABEL org.opencontainers.image.created=${DATE} | ||
LABEL org.opencontainers.image.version=${VERSION} | ||
LABEL com.sourcegraph.github.url=https://github.com/sourcegraph/sourcegraph/commit/${COMMIT_SHA} | ||
|
||
ENTRYPOINT ["/sbin/tini", "--", "/usr/local/bin/loadtest"] | ||
COPY loadtest /usr/local/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/usr/bin/env bash | ||
|
||
# We want to build multiple go binaries, so we use a custom build step on CI. | ||
cd "$(dirname "${BASH_SOURCE[0]}")"/../.. | ||
set -ex | ||
|
||
OUTPUT=$(mktemp -d -t sgdockerbuild_XXXXXXX) | ||
cleanup() { | ||
rm -rf "$OUTPUT" | ||
} | ||
trap cleanup EXIT | ||
|
||
if [[ "${DOCKER_BAZEL:-false}" == "true" ]]; then | ||
|
||
bazel build //cmd/loadtest \ | ||
--stamp \ | ||
--workspace_status_command=./dev/bazel_stamp_vars.sh \ | ||
--platforms=@io_bazel_rules_go//go/toolchain:linux_amd64 | ||
|
||
out=$(bazel cquery //cmd/loadtest --output=files) | ||
cp "$out" "$OUTPUT" | ||
|
||
docker build -f cmd/loadtest/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION | ||
exit $? | ||
fi | ||
|
||
# Environment for building linux binaries | ||
export GO111MODULE=on | ||
export GOARCH=amd64 | ||
export GOOS=linux | ||
export CGO_ENABLED=0 | ||
|
||
pkg="github.com/sourcegraph/sourcegraph/cmd/loadtest" | ||
go build -trimpath -ldflags "-X github.com/sourcegraph/sourcegraph/internal/version.version=$VERSION -X github.com/sourcegraph/sourcegraph/internal/version.timestamp=$(date +%s)" -buildmode exe -tags dist -o "$OUTPUT/$(basename $pkg)" "$pkg" | ||
|
||
docker build -f cmd/loadtest/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Dockerfile for Wolfi-based images | ||
# This is currently being tested in parallel to Alpine - you don't need to update this | ||
# file if you change the regular Dockerfile. | ||
|
||
# hadolint ignore=DL3007 | ||
FROM us.gcr.io/sourcegraph-dev/wolfi-sourcegraph-base:latest | ||
|
||
ARG COMMIT_SHA="unknown" | ||
ARG DATE="unknown" | ||
ARG VERSION="unknown" | ||
|
||
LABEL org.opencontainers.image.revision=${COMMIT_SHA} | ||
LABEL org.opencontainers.image.created=${DATE} | ||
LABEL org.opencontainers.image.version=${VERSION} | ||
LABEL com.sourcegraph.github.url=https://github.com/sourcegraph/sourcegraph/commit/${COMMIT_SHA} | ||
|
||
USER sourcegraph | ||
|
||
ENTRYPOINT ["/sbin/tini", "--", "/usr/local/bin/migrator"] | ||
COPY migrator /usr/local/bin/ | ||
COPY schema-descriptions /schema-descriptions |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
#!/usr/bin/env bash | ||
|
||
# This script builds the migrator docker image. | ||
|
||
cd "$(dirname "${BASH_SOURCE[0]}")/../.." | ||
set -ex | ||
|
||
OUTPUT=$(mktemp -d -t sgdockerbuild_XXXXXXX) | ||
cleanup() { | ||
rm -rf "$OUTPUT" | ||
} | ||
trap cleanup EXIT | ||
|
||
if [[ "${DOCKER_BAZEL:-false}" == "true" ]]; then | ||
|
||
bazel build //cmd/migrator \ | ||
--stamp \ | ||
--workspace_status_command=./dev/bazel_stamp_vars.sh \ | ||
--platforms=@io_bazel_rules_go//go/toolchain:linux_amd64 | ||
|
||
out=$(bazel cquery //cmd/migrator --output=files) | ||
cp "$out" "$OUTPUT" | ||
|
||
docker build -f cmd/migrator/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION | ||
exit $? | ||
fi | ||
|
||
# Environment for building linux binaries | ||
export GO111MODULE=on | ||
export GOARCH=amd64 | ||
export GOOS=linux | ||
export CGO_ENABLED=0 | ||
|
||
echo "--- go build" | ||
pkg=${1:-"github.com/sourcegraph/sourcegraph/cmd/migrator"} | ||
output="$OUTPUT/$(basename "$pkg")" | ||
# shellcheck disable=SC2153 | ||
go build -trimpath -ldflags "-X github.com/sourcegraph/sourcegraph/internal/version.version=$VERSION -X github.com/sourcegraph/sourcegraph/internal/version.timestamp=$(date +%s)" -buildmode exe -tags dist -o "$output" "$pkg" | ||
|
||
echo "--- compile schema descriptions" | ||
mkdir -p "${OUTPUT}/schema-descriptions" | ||
|
||
# See internal/database/migration/cliutil/drift-schemas/generate-all.sh | ||
gcs_versions=( | ||
v3.20.0 v3.20.1 | ||
v3.21.0 v3.21.1 v3.21.2 | ||
v3.22.0 v3.22.1 | ||
v3.23.0 | ||
v3.24.0 v3.24.1 | ||
v3.25.0 v3.25.1 v3.25.2 | ||
v3.26.0 v3.26.1 v3.26.2 v3.26.3 | ||
v3.27.0 v3.27.1 v3.27.2 v3.27.3 v3.27.4 v3.27.5 | ||
v3.28.0 | ||
v3.29.0 v3.29.1 | ||
v3.30.0 v3.30.1 v3.30.2 v3.30.3 v3.30.4 | ||
v3.31.0 v3.31.1 v3.31.2 | ||
v3.32.0 v3.32.1 | ||
v3.33.0 v3.33.1 v3.33.2 | ||
v3.34.0 v3.34.1 v3.34.2 | ||
v3.35.0 v3.35.1 v3.35.2 | ||
v3.36.0 v3.36.1 v3.36.2 v3.36.3 | ||
v3.37.0 | ||
v3.38.0 v3.38.1 | ||
v3.39.0 v3.39.1 | ||
v3.40.0 v3.40.1 v3.40.2 | ||
v3.41.0 v3.41.1 | ||
) | ||
gcs_filenames=( | ||
internal_database_schema.json | ||
internal_database_schema.codeintel.json | ||
internal_database_schema.codeinsights.json | ||
) | ||
|
||
function download_gcs() { | ||
outfile="${OUTPUT}/schema-descriptions/${1}-${2}" | ||
if ! curl -fsSL "https://storage.googleapis.com/sourcegraph-assets/migrations/drift/${1}-${2}" 2>/dev/null >"${outfile}"; then | ||
rm "${outfile}" | ||
fi | ||
} | ||
|
||
for version in "${gcs_versions[@]}"; do | ||
echo "Persisting schemas for ${version} from GCS..." | ||
for filename in "${gcs_filenames[@]}"; do | ||
download_gcs "${version}" "${filename}" | ||
done | ||
done | ||
|
||
git_versions=( | ||
v3.42.0 v3.42.1 v3.42.2 | ||
v3.43.0 v3.43.1 v3.43.2 | ||
v4.0.0 v4.0.1 | ||
v4.1.0 v4.1.1 v4.1.2 v4.1.3 | ||
v4.2.0 v4.2.1 | ||
v4.3.0 v4.3.1 | ||
v4.4.0 v4.4.1 v4.4.2 | ||
v4.5.0 v4.5.1 | ||
v5.0.0 | ||
) | ||
for version in "${git_versions[@]}"; do | ||
echo "Persisting schemas for ${version} from Git..." | ||
git show "${version}:internal/database/schema.json" >"${OUTPUT}/schema-descriptions/${version}-internal_database_schema.json" | ||
git show "${version}:internal/database/schema.codeintel.json" >"${OUTPUT}/schema-descriptions/${version}-internal_database_schema.codeintel.json" | ||
git show "${version}:internal/database/schema.codeinsights.json" >"${OUTPUT}/schema-descriptions/${version}-internal_database_schema.codeinsights.json" | ||
done | ||
|
||
echo "--- docker build" | ||
docker build -f cmd/migrator/Dockerfile.wolfi -t "$IMAGE" "$OUTPUT" \ | ||
--progress=plain \ | ||
--build-arg COMMIT_SHA \ | ||
--build-arg DATE \ | ||
--build-arg VERSION |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You didn't port the bazel build in that one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've just been tracking what the build.sh script on
main
does, and for this image it doesn't use bazel - https://github.com/sourcegraph/sourcegraph/blob/main/cmd/frontend/build.shThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that's because in our branch, it's done in a
build-bazel.sh