Compare commits
8
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0769726d44 | ||
|
|
296b8d7bb9 | ||
|
|
a35595c6de | ||
|
|
e258c32fa6 | ||
|
|
e2af95376a | ||
|
|
b42319aa85 | ||
|
|
6e88d0cf6c | ||
|
|
eef8a1a5ff |
No files matched your search
@@ -39,6 +39,17 @@ jobs:
|
||||
role-to-assume: "arn:aws:iam::080433136561:role/nix-release"
|
||||
role-session-name: nix-release-oidc-${{ github.run_id }}
|
||||
aws-region: eu-west-1
|
||||
- name: Disable containerd image store
|
||||
run: |
|
||||
# Docker 28+ defaults to the containerd image store, which
|
||||
# pushes layers uncompressed instead of gzip. OCI clients
|
||||
# that only support gzip (e.g. go-containerregistry) fail
|
||||
# with "gzip: invalid header". Disabling the containerd
|
||||
# snapshotter restores the classic storage driver, which
|
||||
# preserves gzip-compressed layers through the
|
||||
# `docker load` / `docker push` pipeline.
|
||||
echo '{"features":{"containerd-snapshotter":false}}' | sudo tee /etc/docker/daemon.json > /dev/null
|
||||
sudo systemctl restart docker
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef # v3.6.0
|
||||
with:
|
||||
|
||||
@@ -236,6 +236,9 @@ void Input::checkLocks(Input specified, Input & result)
|
||||
if (auto prevNarHash = specified.getNarHash())
|
||||
specified.attrs.insert_or_assign("narHash", prevNarHash->to_string(HashFormat::SRI, true));
|
||||
|
||||
if (auto narHash = result.getNarHash())
|
||||
result.attrs.insert_or_assign("narHash", narHash->to_string(HashFormat::SRI, true));
|
||||
|
||||
for (auto & field : specified.attrs) {
|
||||
auto field2 = result.attrs.find(field.first);
|
||||
if (field2 != result.attrs.end() && field.second != field2->second)
|
||||
|
||||
+14
-9
@@ -150,18 +150,23 @@ public:
|
||||
|
||||
Verbosity verbosity = lvlInfo;
|
||||
|
||||
void writeToStderr(std::string_view s)
|
||||
static void writeFullLogging(Descriptor fd, std::string_view s)
|
||||
{
|
||||
try {
|
||||
writeFull(getStandardError(), s, false);
|
||||
writeFull(fd, s, false);
|
||||
} catch (SystemError & e) {
|
||||
/* Ignore failing writes to stderr. We need to ignore write
|
||||
errors to ensure that cleanup code that logs to stderr runs
|
||||
to completion if the other side of stderr has been closed
|
||||
unexpectedly. */
|
||||
/* Ignore failing logging writes. We need to ignore write
|
||||
errors to ensure that cleanup code that writes logs runs
|
||||
to completion if the other side of the logging fd has
|
||||
been closed unexpectedly. */
|
||||
}
|
||||
}
|
||||
|
||||
void writeToStderr(std::string_view s)
|
||||
{
|
||||
writeFullLogging(getStandardError(), s);
|
||||
}
|
||||
|
||||
std::unique_ptr<Logger> makeSimpleLogger(bool printBuildLogs)
|
||||
{
|
||||
return std::make_unique<SimpleLogger>(printBuildLogs);
|
||||
@@ -245,15 +250,15 @@ struct JSONLogger : Logger
|
||||
|
||||
void write(const nlohmann::json & json)
|
||||
{
|
||||
auto line =
|
||||
(includeNixPrefix ? "@nix " : "") + json.dump(-1, ' ', false, nlohmann::json::error_handler_t::replace);
|
||||
auto line = (includeNixPrefix ? "@nix " : "")
|
||||
+ json.dump(-1, ' ', false, nlohmann::json::error_handler_t::replace) + "\n";
|
||||
|
||||
/* Acquire a lock to prevent log messages from clobbering each
|
||||
other. */
|
||||
try {
|
||||
auto state(_state.lock());
|
||||
if (state->enabled)
|
||||
writeLine(fd, line);
|
||||
writeFullLogging(fd, line);
|
||||
} catch (...) {
|
||||
bool enabled = false;
|
||||
std::swap(_state.lock()->enabled, enabled);
|
||||
|
||||
Reference in new issue
Block a user