I tried this (which should not return anything):
$ lando ssh -s appserver -u root -c "echo \"10.0.0.132 pds\" >> /etc/hosts"
10.0.0.132 pds >> /etc/hosts
$ lando ssh -s appserver -u root -c "cat /etc/hosts"
127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
172.26.0.2 8da36421fdb0
172.19.0.3 8da36421fdb0
172.18.0.4 8da36421fdb0
Which shows it was not added. When I enter as root and do it within the container, then it works.
I would like to automate this in a build script. How? What am I doing wrong?
Apparently this can be accomplished with "docker run --add-host" but how do you include this in the .lando.yml file?