Skip to content

chore: remove -a from git tag to avoid launching editor (#324) #47

chore: remove -a from git tag to avoid launching editor (#324)

chore: remove -a from git tag to avoid launching editor (#324) #47

Workflow file for this run

{
"jobs": {
"build_and_test": {
"name": "build_and_test ${{ matrix.host.os }}",
"runs-on": "${{ matrix.host.os }}",
"steps": [
{
"name": "Check out source code",
"uses": "actions/checkout@v1"
},
{
"name": "Installing Bazel",
"run": "v=$(cat .bazelversion) && curl -L https://github.com/bazelbuild/bazel/releases/download/${v}/bazel-${v}-${{matrix.host.bazel_os}}-x86_64 > ~/bazel && chmod +x ~/bazel && echo ~ >> ${GITHUB_PATH}",
"shell": "bash"
},
{
"if": "matrix.host.platform_name == 'windows_amd64'",
"name": "Override .bazelrc",
"run": "echo \"startup --output_base=D:/bazel_output\" >> .bazelrc"
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'linux_amd64'",
"name": "linux_amd64: build${{ matrix.host.platform_name == 'linux_amd64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'linux_amd64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.linux_amd64",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.linux_amd64",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.linux_amd64",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.linux_amd64",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'linux_amd64_v3'",
"name": "linux_amd64_v3: build${{ matrix.host.platform_name == 'linux_amd64_v3' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'linux_amd64_v3' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64_v3 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64_v3 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.linux_amd64_v3",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64_v3 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.linux_amd64_v3",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64_v3 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.linux_amd64_v3",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_amd64_v3 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "linux_amd64_v3: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.linux_amd64_v3",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'linux_386'",
"name": "linux_386: build${{ matrix.host.platform_name == 'linux_amd64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'linux_amd64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_386 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "linux_386: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_386 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "linux_386: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.linux_386",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "linux_386: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_386 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "linux_386: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.linux_386",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "linux_386: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_386 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "linux_386: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.linux_386",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "linux_386: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_386 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "linux_386: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.linux_386",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'linux_arm'",
"name": "linux_arm: build${{ matrix.host.platform_name == 'linux_arm' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'linux_arm' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "linux_arm: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "linux_arm: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.linux_arm",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "linux_arm: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "linux_arm: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.linux_arm",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "linux_arm: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "linux_arm: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.linux_arm",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "linux_arm: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "linux_arm: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.linux_arm",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'linux_arm64'",
"name": "linux_arm64: build${{ matrix.host.platform_name == 'linux_arm64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'linux_arm64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm64 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm64 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.linux_arm64",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm64 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.linux_arm64",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm64 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.linux_arm64",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:linux_arm64 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "linux_arm64: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.linux_arm64",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'darwin_amd64'",
"name": "darwin_amd64: build${{ matrix.host.platform_name == 'darwin_amd64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'darwin_amd64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_amd64 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_amd64 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.darwin_amd64",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_amd64 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.darwin_amd64",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_amd64 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.darwin_amd64",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_amd64 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "darwin_amd64: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.darwin_amd64",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'darwin_arm64'",
"name": "darwin_arm64: build${{ matrix.host.platform_name == 'darwin_arm64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'darwin_arm64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_arm64 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_arm64 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.darwin_arm64",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_arm64 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.darwin_arm64",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_arm64 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.darwin_arm64",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:darwin_arm64 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "darwin_arm64: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.darwin_arm64",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'freebsd_amd64'",
"name": "freebsd_amd64: build${{ matrix.host.platform_name == 'freebsd_amd64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'freebsd_amd64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:freebsd_amd64 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: copy bb_copy",
"run": "rm -f bb_copy && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:freebsd_amd64 //cmd/bb_copy $(pwd)/bb_copy"
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.freebsd_amd64",
"path": "bb_copy"
}
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: copy bb_replicator",
"run": "rm -f bb_replicator && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:freebsd_amd64 //cmd/bb_replicator $(pwd)/bb_replicator"
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.freebsd_amd64",
"path": "bb_replicator"
}
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: copy bb_storage",
"run": "rm -f bb_storage && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:freebsd_amd64 //cmd/bb_storage $(pwd)/bb_storage"
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.freebsd_amd64",
"path": "bb_storage"
}
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:freebsd_amd64 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap"
},
{
"if": "matrix.host.upload",
"name": "freebsd_amd64: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.freebsd_amd64",
"path": "sync_jwks_to_configmap"
}
},
{
"if": "matrix.host.cross_compile || matrix.host.platform_name == 'windows_amd64'",
"name": "windows_amd64: build${{ matrix.host.platform_name == 'windows_amd64' && ' and test' || '' }}",
"run": "bazel ${{ matrix.host.platform_name == 'windows_amd64' && 'test --test_output=errors' || 'build --platforms=@com_github_buildbarn_bb_storage//tools/platforms:windows_amd64 --@bazel_tools//tools/test:incompatible_use_default_test_toolchain=False' }} //..."
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: copy bb_copy",
"run": "rm -f bb_copy.exe && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:windows_amd64 //cmd/bb_copy $(pwd)/bb_copy.exe"
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: upload bb_copy",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_copy.windows_amd64",
"path": "bb_copy.exe"
}
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: copy bb_replicator",
"run": "rm -f bb_replicator.exe && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:windows_amd64 //cmd/bb_replicator $(pwd)/bb_replicator.exe"
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: upload bb_replicator",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_replicator.windows_amd64",
"path": "bb_replicator.exe"
}
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: copy bb_storage",
"run": "rm -f bb_storage.exe && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:windows_amd64 //cmd/bb_storage $(pwd)/bb_storage.exe"
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: upload bb_storage",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "bb_storage.windows_amd64",
"path": "bb_storage.exe"
}
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: copy sync_jwks_to_configmap",
"run": "rm -f sync_jwks_to_configmap.exe && bazel run --run_under cp --platforms=@com_github_buildbarn_bb_storage//tools/platforms:windows_amd64 //cmd/sync_jwks_to_configmap $(pwd)/sync_jwks_to_configmap.exe"
},
{
"if": "matrix.host.upload",
"name": "windows_amd64: upload sync_jwks_to_configmap",
"uses": "actions/upload-artifact@v4",
"with": {
"name": "sync_jwks_to_configmap.windows_amd64",
"path": "sync_jwks_to_configmap.exe"
}
},
{
"env": {
"GITHUB_TOKEN": "${{ secrets.GITHUB_TOKEN }}"
},
"if": "matrix.host.upload",
"name": "Install Docker credentials",
"run": "echo \"${GITHUB_TOKEN}\" | docker login ghcr.io -u $ --password-stdin"
},
{
"if": "matrix.host.upload",
"name": "Clean Bazel cache from previous steps",
"run": "bazel clean"
},
{
"if": "matrix.host.upload",
"name": "Push container bb_copy:bb_copy",
"run": "bazel run --stamp //cmd/bb_copy:bb_copy_container_push"
},
{
"if": "matrix.host.upload",
"name": "Push container bb_replicator:bb_replicator",
"run": "bazel run --stamp //cmd/bb_replicator:bb_replicator_container_push"
},
{
"if": "matrix.host.upload",
"name": "Push container bb_storage:bb_storage",
"run": "bazel run --stamp //cmd/bb_storage:bb_storage_container_push"
},
{
"if": "matrix.host.upload",
"name": "Push container sync_jwks_to_configmap:sync_jwks_to_configmap",
"run": "bazel run --stamp //cmd/sync_jwks_to_configmap:sync_jwks_to_configmap_container_push"
}
],
"strategy": {
"matrix": {
"host": [
{
"bazel_os": "linux",
"cross_compile": true,
"os": "ubuntu-latest",
"platform_name": "linux_amd64",
"upload": true
},
{
"bazel_os": "windows",
"cross_compile": false,
"os": "windows-latest",
"platform_name": "windows_amd64",
"upload": false
}
]
}
}
},
"lint": {
"name": "lint",
"runs-on": "ubuntu-latest",
"steps": [
{
"name": "Check out source code",
"uses": "actions/checkout@v1"
},
{
"name": "Installing Bazel",
"run": "v=$(cat .bazelversion) && curl -L https://github.com/bazelbuild/bazel/releases/download/${v}/bazel-${v}-linux-x86_64 > ~/bazel && chmod +x ~/bazel && echo ~ >> ${GITHUB_PATH}",
"shell": "bash"
},
{
"name": "Reformat",
"run": "bazel run @com_github_buildbarn_bb_storage//tools:reformat"
},
{
"name": "Test style conformance",
"run": "git add . && git diff --exit-code HEAD --"
},
{
"name": "Golint",
"run": "bazel run @org_golang_x_lint//golint -- -set_exit_status $(pwd)/..."
}
]
},
"publish": {
"name": "publish",
"needs": [
"build_and_test"
],
"runs-on": "ubuntu-latest",
"steps": [
{
"name": "Checkout the repository",
"uses": "actions/checkout@v4 "
},
{
"name": "Download release artifacts",
"uses": "actions/download-artifact@v4",
"with": {
"merge-multiple": true,
"path": "assets"
}
},
{
"name": "Calculate shasum",
"run": "shasum -a 256 assets/* > sha256"
},
{
"name": "Set release Git user",
"run": "git config --global user.email \"41898282+github-actions[bot]@users.noreply.github.com\"\ngit config --global user.name \"github-actions[bot]\"\n"
},
{
"id": "create_tag",
"name": "Generate tag",
"run": "BUILD_SCM_REVISION=$(git rev-parse --short HEAD)\nBUILD_SCM_TIMESTAMP=$(TZ=UTC date --date \"@$(git show -s --format=%ct HEAD)\" +%Y%m%dT%H%M%SZ)\nRELEASE_TAG=\"${BUILD_SCM_TIMESTAMP}-${BUILD_SCM_REVISION}}\"\ngit tag $RELEASE_TAG\ngit push --follow-tags\necho \"release_tag=$RELEASE_TAG\" >> $GITHUB_OUTPUT\n"
},
{
"name": "Create GitHub release and upload artifacts",
"uses": "softprops/action-gh-release@v2",
"with": {
"files": "assets/*\nsha256\n",
"make_latest": true,
"tag_name": "${{ steps.create_tag.outputs.release_tag }}"
}
}
]
}
},
"name": "main",
"on": {
"push": {
"branches": [
"main"
]
}
}
}