summaryrefslogtreecommitdiff
path: root/setup-hostname.in
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2009-05-06 09:53:36 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2009-05-06 09:53:36 +0000
commitec0c7a74bbf5824adc4efa54e1f91984ac870a8e (patch)
tree7f5a8763836154b10c8325629b493ebc67ead7e6 /setup-hostname.in
parentf590563940559429ffe77094473d12361937852d (diff)
downloadalpine-conf-ec0c7a74bbf5824adc4efa54e1f91984ac870a8e.zip
move to .in files
Diffstat (limited to 'setup-hostname.in')
-rwxr-xr-xsetup-hostname.in14
1 files changed, 14 insertions, 0 deletions
diff --git a/setup-hostname.in b/setup-hostname.in
new file mode 100755
index 0000000..b1c2379
--- /dev/null
+++ b/setup-hostname.in
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+PROGRAM=setup-hostname
+PREFIX=
+
+. $PREFIX/lib/libalpine.sh
+
+HOST=`hostname`
+echon "Enter system hostname (short form, e.g. 'foo') [$HOST]: "
+default_read HOST `hostname`
+
+mkdir -p "$ROOT/etc"
+echo "$HOST" > "$ROOT/etc/hostname"
+