Fix B2 foundation proof for Compose omitted false bind option
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
# B2 foundation: Compose 2.20.1 serialization regression
|
||||
|
||||
These JSON files are real `config --format json` output, generated from the
|
||||
synthetic, secret-free `base.yml` and the exact production `override.yml`.
|
||||
No Docker daemon, container, worker or production mutation is involved.
|
||||
|
||||
Official Docker Compose v2.20.1 Darwin arm64 release binary SHA256:
|
||||
`e5449e23d14740092c4e764dd9e66cc693d8b02747167c045fd4edfd64fda958`.
|
||||
Source: <https://github.com/docker/compose/releases/tag/v2.20.1>.
|
||||
This is the upstream parser version; the NAS build is
|
||||
`2.20.1-6047-g6817716`, not this exact binary.
|
||||
|
||||
Generate from this directory, using a separately SHA-verified binary:
|
||||
|
||||
```sh
|
||||
"$COMPOSE_BINARY" -p nodedc-device-plane --env-file /dev/null \
|
||||
--project-directory /volume1/docker/nodedc-device-plane \
|
||||
-f base.yml config --format json > base.json
|
||||
"$COMPOSE_BINARY" -p nodedc-device-plane --env-file /dev/null \
|
||||
--project-directory /volume1/docker/nodedc-device-plane \
|
||||
-f base.yml -f override.yml config --format json > candidate.json
|
||||
```
|
||||
|
||||
JSON whitespace is formatted with Python `json.dumps(..., indent=2)`.
|
||||
The new mount emits `bind: {}` and omits `read_only`: both booleans are false.
|
||||
Runner016 incorrectly expected an explicit `create_host_path: false` property.
|
||||
Runner017 removes that exact false property only from the new B2 mount inside
|
||||
comparison copies. Raw config, its digest, fixed YAML, all old mounts and
|
||||
other properties stay exact. True/null/numeric/string values and unknown bind
|
||||
options are rejected. The source YAML must still explicitly disable directory
|
||||
creation; accepting this JSON output cannot authorize a different YAML.
|
||||
|
||||
The same failure and fix were also reproduced using all five current NAS
|
||||
Compose files through SMB, without reading any referenced secret file.
|
||||
Only filenames, hashes and comparison outcomes are retained in public evidence;
|
||||
the full effective configuration is not a fixture or a deploy payload.
|
||||
@@ -0,0 +1,67 @@
|
||||
{
|
||||
"name": "nodedc-device-plane",
|
||||
"networks": {
|
||||
"default": {
|
||||
"name": "nodedc-device-plane_default",
|
||||
"ipam": {},
|
||||
"external": false
|
||||
},
|
||||
"egress": {
|
||||
"name": "nodedc-device-plane_egress",
|
||||
"ipam": {},
|
||||
"external": false
|
||||
},
|
||||
"private": {
|
||||
"name": "nodedc-device-plane_private",
|
||||
"ipam": {},
|
||||
"external": false,
|
||||
"internal": true
|
||||
}
|
||||
},
|
||||
"services": {
|
||||
"device-control-core": {
|
||||
"command": null,
|
||||
"entrypoint": null,
|
||||
"environment": {
|
||||
"EXISTING": "synthetic-preserved"
|
||||
},
|
||||
"image": "nodedc/device-control-core:local",
|
||||
"networks": {
|
||||
"egress": {},
|
||||
"private": {
|
||||
"priority": 100
|
||||
}
|
||||
},
|
||||
"volumes": [
|
||||
{
|
||||
"type": "bind",
|
||||
"source": "/synthetic/existing-secret-reference",
|
||||
"target": "/run/existing-secret-reference",
|
||||
"read_only": true,
|
||||
"bind": {}
|
||||
}
|
||||
]
|
||||
},
|
||||
"device-postgres": {
|
||||
"command": null,
|
||||
"entrypoint": null,
|
||||
"image": "postgres:16",
|
||||
"networks": {
|
||||
"default": null
|
||||
},
|
||||
"volumes": [
|
||||
{
|
||||
"type": "volume",
|
||||
"source": "existing-data",
|
||||
"target": "/var/lib/postgresql/data"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"volumes": {
|
||||
"existing-data": {
|
||||
"name": "nodedc-device-plane_existing-data",
|
||||
"external": false
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
services:
|
||||
device-control-core:
|
||||
image: nodedc/device-control-core:local
|
||||
environment:
|
||||
EXISTING: synthetic-preserved
|
||||
volumes:
|
||||
- type: bind
|
||||
source: /synthetic/existing-secret-reference
|
||||
target: /run/existing-secret-reference
|
||||
read_only: true
|
||||
bind:
|
||||
create_host_path: false
|
||||
networks:
|
||||
private:
|
||||
priority: 100
|
||||
egress:
|
||||
priority: 0
|
||||
device-postgres:
|
||||
image: postgres:16
|
||||
volumes:
|
||||
- type: volume
|
||||
source: existing-data
|
||||
target: /var/lib/postgresql/data
|
||||
networks:
|
||||
private:
|
||||
internal: true
|
||||
egress: {}
|
||||
volumes:
|
||||
existing-data: {}
|
||||
@@ -0,0 +1,74 @@
|
||||
{
|
||||
"name": "nodedc-device-plane",
|
||||
"networks": {
|
||||
"default": {
|
||||
"name": "nodedc-device-plane_default",
|
||||
"ipam": {},
|
||||
"external": false
|
||||
},
|
||||
"egress": {
|
||||
"name": "nodedc-device-plane_egress",
|
||||
"ipam": {},
|
||||
"external": false
|
||||
},
|
||||
"private": {
|
||||
"name": "nodedc-device-plane_private",
|
||||
"ipam": {},
|
||||
"external": false,
|
||||
"internal": true
|
||||
}
|
||||
},
|
||||
"services": {
|
||||
"device-control-core": {
|
||||
"command": null,
|
||||
"entrypoint": null,
|
||||
"environment": {
|
||||
"DEVICE_B2_SECRET_ROOT": "/run/nodedc-b2-connections",
|
||||
"EXISTING": "synthetic-preserved"
|
||||
},
|
||||
"image": "nodedc/device-control-core:local",
|
||||
"networks": {
|
||||
"egress": {},
|
||||
"private": {
|
||||
"priority": 100
|
||||
}
|
||||
},
|
||||
"volumes": [
|
||||
{
|
||||
"type": "bind",
|
||||
"source": "/synthetic/existing-secret-reference",
|
||||
"target": "/run/existing-secret-reference",
|
||||
"read_only": true,
|
||||
"bind": {}
|
||||
},
|
||||
{
|
||||
"type": "bind",
|
||||
"source": "/volume1/docker/nodedc-device-plane/private-b2-connections",
|
||||
"target": "/run/nodedc-b2-connections",
|
||||
"bind": {}
|
||||
}
|
||||
]
|
||||
},
|
||||
"device-postgres": {
|
||||
"command": null,
|
||||
"entrypoint": null,
|
||||
"image": "postgres:16",
|
||||
"networks": {
|
||||
"default": null
|
||||
},
|
||||
"volumes": [
|
||||
{
|
||||
"type": "volume",
|
||||
"source": "existing-data",
|
||||
"target": "/var/lib/postgresql/data"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"volumes": {
|
||||
"existing-data": {
|
||||
"name": "nodedc-device-plane_existing-data",
|
||||
"external": false
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
services:
|
||||
device-control-core:
|
||||
environment:
|
||||
DEVICE_B2_SECRET_ROOT: /run/nodedc-b2-connections
|
||||
volumes:
|
||||
- type: bind
|
||||
source: /volume1/docker/nodedc-device-plane/private-b2-connections
|
||||
target: /run/nodedc-b2-connections
|
||||
read_only: false
|
||||
bind:
|
||||
create_host_path: false
|
||||
Reference in New Issue
Block a user