Commit 678c53ff authored by Alessandro Rubini's avatar Alessandro Rubini

config: allow specification of the NTP server

At configuration time, before building, users can select
the ntpserver to be used to prime WR time at boot.  By default
no server is queried.
Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
parent d362bb50
......@@ -36,6 +36,14 @@ endchoice
menu "Local configuration"
config NTP_SERVER
string "IP address of local NTP server (empty for none)"
help
At boot time, the White Rabbit time is primed by querying
an NTP server, if any is there. Please write here the
IPV4 address (e.g.: "192.168.16.1"); an empty string
disables NTP-based priming.
config KEEP_ROOTFS
bool "Keep generated filesystem and related script"
help
......
......@@ -41,6 +41,10 @@ rm -rf $TMPFS/dev
(cd $TMPFS && tar xzf $DEVTAR)
(cd $TMPFS && ln -fs sbin/init .)
if [ ! -z "$CONFIG_NTP_SERVER" ]; then
echo "ntpserver $CONFIG_NTP_SERVER" > $TMPFS/wr/etc/wr_date.conf
fi
mkdir -p $TMPFS/root/.ssh
#cat $HOME/.ssh/id_?sa.pub >> $TMPFS/root/.ssh/authorized_keys
if [ -f $WRS_BASE_DIR/authorized_keys ]; then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment