102 lines
3.4 KiB
YAML
102 lines
3.4 KiB
YAML
# AB Legacy PCCC integration-test fixture — ab_server in PCCC mode.
|
|
#
|
|
# Same image as the AB CIP fixture (otopcua-ab-server:libplctag-release).
|
|
# The build context points at the AB CIP Docker folder one directory over
|
|
# so `docker compose build` from here produces the same image if it
|
|
# doesn't already exist; if it does, docker's cache reuses the layer.
|
|
#
|
|
# One service per PCCC family. All bind :44818 on the host; run one at a
|
|
# time. PCCC tag format differs from CIP: `<file>[<size>]` without a
|
|
# type suffix since the type is implicit in the file letter (N = INT,
|
|
# F = REAL, B = bit-packed, L = DINT).
|
|
#
|
|
# Usage:
|
|
# docker compose --profile slc500 up
|
|
# docker compose --profile micrologix up
|
|
# docker compose --profile plc5 up
|
|
services:
|
|
slc500:
|
|
profiles: ["slc500"]
|
|
build:
|
|
context: ../../ZB.MOM.WW.OtOpcUa.Driver.AbCip.IntegrationTests/Docker
|
|
dockerfile: Dockerfile
|
|
image: otopcua-ab-server:libplctag-release
|
|
container_name: otopcua-ab-server-slc500
|
|
restart: "no"
|
|
ports:
|
|
- "44818:44818"
|
|
command: [
|
|
"ab_server",
|
|
"--plc=SLC500",
|
|
"--port=44818",
|
|
"--tag=N7[120]",
|
|
"--tag=F8[120]",
|
|
"--tag=B3[10]",
|
|
"--tag=L19[10]"
|
|
]
|
|
|
|
micrologix:
|
|
profiles: ["micrologix"]
|
|
image: otopcua-ab-server:libplctag-release
|
|
build:
|
|
context: ../../ZB.MOM.WW.OtOpcUa.Driver.AbCip.IntegrationTests/Docker
|
|
dockerfile: Dockerfile
|
|
container_name: otopcua-ab-server-micrologix
|
|
restart: "no"
|
|
ports:
|
|
- "44818:44818"
|
|
command: [
|
|
"ab_server",
|
|
"--plc=Micrologix",
|
|
"--port=44818",
|
|
"--tag=B3[10]",
|
|
"--tag=N7[120]",
|
|
"--tag=L19[10]"
|
|
]
|
|
|
|
plc5:
|
|
profiles: ["plc5"]
|
|
image: otopcua-ab-server:libplctag-release
|
|
build:
|
|
context: ../../ZB.MOM.WW.OtOpcUa.Driver.AbCip.IntegrationTests/Docker
|
|
dockerfile: Dockerfile
|
|
container_name: otopcua-ab-server-plc5
|
|
restart: "no"
|
|
ports:
|
|
- "44818:44818"
|
|
command: [
|
|
"ab_server",
|
|
"--plc=PLC/5",
|
|
"--port=44818",
|
|
"--tag=N7[120]",
|
|
"--tag=F8[120]",
|
|
"--tag=B3[10]"
|
|
]
|
|
|
|
# PR ablegacy-12 / #255 — faulty-PLC fixture for the auto-demote contract.
|
|
# FIXTURE-TIER FOLLOW-UP: implementing a refusing-proxy container that
|
|
# round-trips libplctag's CIP framing far enough to trigger comm failures
|
|
# (vs. just RST'ing the TCP handshake) is non-trivial — the integration
|
|
# test currently uses 127.0.0.1:1 (the bogus-port standard) which RST's
|
|
# immediately on most TCP stacks. That gets us deterministic comm-failure
|
|
# coverage without standing up a second container; if the localhost:1
|
|
# trick stops working on a future test runner (e.g. a sandbox that
|
|
# blocks port 1) re-enable this stub:
|
|
#
|
|
# slc500-faulty:
|
|
# profiles: ["slc500-faulty"]
|
|
# image: otopcua-ab-server:libplctag-release
|
|
# build:
|
|
# context: ../../ZB.MOM.WW.OtOpcUa.Driver.AbCip.IntegrationTests/Docker
|
|
# dockerfile: Dockerfile
|
|
# container_name: otopcua-ab-server-slc500-faulty
|
|
# restart: "no"
|
|
# ports:
|
|
# - "44819:44819"
|
|
# # Hostile entrypoint: bind the port but exit immediately so subsequent
|
|
# # connection attempts get RST'd. Future iteration: a libplctag-aware
|
|
# # proxy that accepts the CIP open and then drops the wire halfway
|
|
# # through, exercising the read-timeout path rather than the
|
|
# # connection-refused path.
|
|
# entrypoint: ["sh", "-c", "exit 1"]
|