1#!/bin/sh 2 3# Very early init, used to make sure devices and network are set up and 4# reachable. 5 6set -ex 7 8cd / 9 10mount -t proc none /proc 11mount -t sysfs none /sys 12mount -t devtmpfs none /dev || echo possibly already mounted 13mkdir -p /dev/pts 14mount -t devpts devpts /dev/pts 15mount -t tmpfs tmpfs /tmp 16 17echo "nameserver 8.8.8.8" > /etc/resolv.conf 18[ -z "$NFS_SERVER_IP" ] || echo "$NFS_SERVER_IP caching-proxy" >> /etc/hosts 19 20# Set the time so we can validate certificates before we fetch anything; 21# however as not all DUTs have network, make this non-fatal. 22for i in 1 2 3; do sntp -sS pool.ntp.org && break || sleep 2; done || true 23