sourcegraph/cmd/server
Jean-Hadrien Chabran ee4b4007aa
Running binaries with SANITY_CHECK=true immediately exits with a code zero (#52186)
As we're using
https://github.com/GoogleContainerTools/container-structure-test when
building images with Bazel, we can write tests that ensures that the
binaries we produced are executable on the current platform.

The code using this feature is not present in this PR, as it makes it
much more readable for everyone to ship this independently.

We may still be bitten by `init()` functions, but we'll set low timeouts
on those container structure tests to ensure it stays quick.

## Test plan

<!-- All pull requests REQUIRE a test plan:
https://docs.sourcegraph.com/dev/background-information/testing_principles
-->



```
~/work/other  jh/sanity_check $ SANITY_CHECK=true ./bazel-bin/docker-images/syntax-highlighter/syntect_server
Sanity check passed, exiting without error

~/work/other U jh/sanity_check $ ./bazel-bin/docker-images/syntax-highlighter/syntect_server  
## Embedded themes:

- `InspiredGitHub`
- `Monokai`
- `Solarized (dark)`
# ... 
```

```
~/work/other  jh/sanity_check $ SANITY_CHECK=true bazel-bin/cmd/worker/worker_/worker
Sanity check passed, exiting without error

```
2023-05-19 12:30:11 +00:00
..
internal Housekeeping: fix some code smells in the Go code (#49995) 2023-03-28 20:31:32 +09:00
rootfs dev: add shfmt for shell script consistency (#9900) 2020-04-15 12:44:36 -07:00
shared Add embeddings to server behind env var (#50288) 2023-04-04 16:45:50 +02:00
build-bazel.sh ci: enable bazel builds for docker images (#51241) 2023-04-28 10:41:13 +02:00
build-wolfi.sh Apply Wolfi Cloud Instance Fixes (#51263) 2023-05-18 10:48:43 +01:00
BUILD.bazel Running binaries with SANITY_CHECK=true immediately exits with a code zero (#52186) 2023-05-19 12:30:11 +00:00
build.sh Deploy Wolfi-based Grafana image (#48992) 2023-03-09 13:41:25 +01:00
Dockerfile Bump syntax-highlighter docker container for single-docker deployment (#51616) 2023-05-09 18:28:55 +02:00
Dockerfile.bazel ci: enable bazel builds for docker images (#51241) 2023-04-28 10:41:13 +02:00
Dockerfile.wolfi Build Wolfi images (#47182) 2023-04-24 17:32:36 +00:00
go-build-wolfi.sh Apply Wolfi Cloud Instance Fixes (#51263) 2023-05-18 10:48:43 +01:00
go-build.sh cmd(server): fix build version embed (#11633) 2020-06-22 23:50:42 +08:00
main.go Running binaries with SANITY_CHECK=true immediately exits with a code zero (#52186) 2023-05-19 12:30:11 +00:00
pre-build.sh ci: add shellcheck linter for shell scripts (#9903) 2020-04-21 10:03:17 -07:00