aboutsummaryrefslogtreecommitdiff
path: root/genenetwork-development-deploy.sh
blob: d39bb7f212480a531c44b221a001f70fe87b76a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#! /bin/sh -e

# genenetwork-machines --- Guix configuration for genenetwork machines
# Copyright © 2022–2024 Arun Isaac <arunisaac@systemreboot.net>
#
# This file is part of genenetwork-machines.
#
# genenetwork-machines is free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 3 of
# the License, or (at your option) any later version.
#
# genenetwork-machines is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied warranty
# of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with genenetwork-machines.  If not, see
# <https://www.gnu.org/licenses/>.

# Build and install genenetwork development container on penguin2.

# If we shared only the mysqld.sock socket file, it would break when
# the external mysqld server is restarted. So, we share the mysqld
# socket directory.

# We set permissions on the secret files. So, we share
# /etc/genenetwork/conf instead of merely exposing it.
container_script=$(guix system container --network \
                        --verbosity=3 \
                        --load-path=. \
                        --share=/home/git/public \
                        --share=/var/guix/daemon-socket=/var/host-guix/daemon-socket \
                        --share=/export2/guix-containers/genenetwork-development/var/lib/acme=/var/lib/acme \
                        --share=/export2/guix-containers/genenetwork-development/var/lib/laminar=/var/lib/laminar \
                        --share=/export2/guix-containers/genenetwork-development/var/lib/tissue=/var/lib/tissue \
                        --share=/export2/guix-containers/genenetwork-development/var/lib/virtuoso=/var/lib/virtuoso \
                        --share=/export2/guix-containers/genenetwork-development/var/log/cd=/var/log/cd \
                        --share=/export2/guix-containers/genenetwork-development/etc/genenetwork/conf=/etc/genenetwork/conf \
			--share=/export/data/genenetwork-virtuoso=/var/lib/data \
                        --expose=/export/data/genenetwork \
                        --share=/export/data/genenetwork-xapian \
                        --share=/export/data/genenetwork-sqlite \
                        --share=/export/genenetwork-database-dump \
                        --share=/var/run/mysqld=/run/mysqld \
                        genenetwork-development.scm)

echo $container_script
sudo ln --force --symbolic $container_script /usr/local/bin/genenetwork-development-container
sudo ln --force --symbolic /usr/local/bin/genenetwork-development-container /var/guix/gcroots