Render once on the leader
Read this right after A node failing, with
placed on far01 and the other deployments on home01. Every command here
reads; none changes the cluster.
One node leads the cluster:
$ shc node lsNAME STATE CONDITION AVAIL CLOUD LOCATION ROOM BUILD LEADER VOTERfar01 healthy ready active learn learn/far ok 0.1.2 no nohome01 healthy ready active learn learn/home ok 0.1.2 yes yeshome02 healthy ready active learn learn/home ok 0.1.2 no noThe leader renders each deployment from its app once, at install or update, and stores the result. It keeps the rendered tree of every deployment:
$ ls -1 /var/lib/shc/deployments/prodclouddbpgwebplacedstorewebA node that runs a replica gets that replica’s part of the render, a compose
file and a replica record, and runs it. placed runs on far01, and far01
holds placed’s files and no other deployment’s. Its replica’s directory
carries -i1, the incarnation the move to far01 started. members is
empty: the last page’s uninstall took its files and left the directory.
$ ls -1 /run/shc-secrets/.projects/prod/prodmembersplaced$ ls -1 /run/shc-secrets/.projects/prod/prod/members$ ls -1 /run/shc-secrets/.projects/prod/prod/placedpostgres-r0-i1$ ls -1 /run/shc-secrets/.projects/prod/prod/placed/postgres-r0-i1compose.yamlreplica.json/run is a memory filesystem, so the rendered secrets in those files never
reach the node’s disk:
$ stat -f -c %T /runtmpfsThis is the last page of the app ladder. Learn SHC lists the ladders that go on from it.