aboutsummaryrefslogtreecommitdiff
path: root/containers/db-container.sh
diff options
context:
space:
mode:
Diffstat (limited to 'containers/db-container.sh')
-rwxr-xr-xcontainers/db-container.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/containers/db-container.sh b/containers/db-container.sh
new file mode 100755
index 00000000..bbe0247a
--- /dev/null
+++ b/containers/db-container.sh
@@ -0,0 +1,12 @@
+#! /bin/sh -e
+
+# Find path to containers directory.
+containers=$(dirname $0)
+
+# Create mariadb state directory if it does not exist.
+mkdir -p $containers/mariadb-state
+
+# Build the container.
+guix system container --network \
+ --share=$containers/mariadb-state=/var/lib/mysql \
+ $containers/db-container.scm