Artifact f297bf7c02018af4606c89b02b98307f2ec2f797:
- Executable file utils/homehost_check.sh — part of check-in [3e82d9d73f] at 2017-01-13 17:05:13 on branch v1.63 — adding script to do check whether on home host (user: bjbarcla, size: 348) [annotate] [blame] [check-ins using] [more...]
#!/bin/sh #exits 1 when current host is not homehost. if [[ ! -e .homehost ]]; then exit 0 fi homehostname=$( host `cat .homehost` | awk '{print $NF}' | sed 's/\.$//' ) hostname=$( hostname -f ) if [[ $homehostname == $hostname ]]; then exit 0 fi echo "ERROR: this host ($homehostname) is not the megatest homehost ($hostname)" exit 1