summaryrefslogtreecommitdiffstats
path: root/setup-hostname
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2006-10-14 09:31:03 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2006-10-14 09:31:03 +0000
commitccaf94592342255f3f0692c242196fb157a48137 (patch)
treeead59f55d6eedb39843ff755962e03a25e3f78c6 /setup-hostname
downloadalpine-conf-ccaf94592342255f3f0692c242196fb157a48137.tar.bz2
alpine-conf-ccaf94592342255f3f0692c242196fb157a48137.tar.xz
intial import - version 0.6.0
Diffstat (limited to 'setup-hostname')
-rwxr-xr-xsetup-hostname14
1 files changed, 14 insertions, 0 deletions
diff --git a/setup-hostname b/setup-hostname
new file mode 100755
index 0000000..b1c2379
--- /dev/null
+++ b/setup-hostname
@@ -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"
+