mirror of
https://github.com/project-zot/zot.git
synced 2024-12-30 22:34:13 -05:00
fix: freebsd build support (#1659)
- Avoid hard-coding the path for bash - this typically is installed as /usr/local/bin/bash - Allow for the fact that FreeBSD's rlimit uses signed integers Almost all of the test suite passes with three test failures that I haven't tried to debug yet. Signed-off-by: Doug Rabson <dfr@rabson.org>
This commit is contained in:
parent
fc47fb91e1
commit
20391a21c0
4 changed files with 9 additions and 5 deletions
|
@ -75,7 +75,7 @@ func DumpRuntimeParams(log log.Logger) {
|
||||||
|
|
||||||
err := syscall.Getrlimit(syscall.RLIMIT_NOFILE, &rLimit)
|
err := syscall.Getrlimit(syscall.RLIMIT_NOFILE, &rLimit)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
evt = evt.Uint64("max. open files", rLimit.Cur)
|
evt = evt.Uint64("max. open files", uint64(rLimit.Cur)) //nolint: unconvert // required for *BSD
|
||||||
}
|
}
|
||||||
|
|
||||||
if content, err := os.ReadFile("/proc/sys/net/core/somaxconn"); err == nil {
|
if content, err := os.ReadFile("/proc/sys/net/core/somaxconn"); err == nil {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
@ -15,4 +15,4 @@ do
|
||||||
parentDir=$(dirname $file)
|
parentDir=$(dirname $file)
|
||||||
go test $parentDir -run=$func -fuzz=$func$ -fuzztime=${fuzzTime}s -tags sync,metrics,search,scrub,containers_image_openpgp | grep -oP -x '^(?:(?!\blevel\b).)*$'
|
go test $parentDir -run=$func -fuzz=$func$ -fuzztime=${fuzzTime}s -tags sync,metrics,search,scrub,containers_image_openpgp | grep -oP -x '^(?:(?!\blevel\b).)*$'
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
#!/bin/bash -xe
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -xe
|
||||||
|
|
||||||
openssl req \
|
openssl req \
|
||||||
-newkey rsa:2048 \
|
-newkey rsa:2048 \
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
#!/bin/bash -xe
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -xe
|
||||||
|
|
||||||
openssl req \
|
openssl req \
|
||||||
-newkey rsa:2048 \
|
-newkey rsa:2048 \
|
||||||
|
|
Loading…
Reference in a new issue