Replace numbered build scripts with updated ones
This commit is contained in:
@@ -1,8 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
source /build/config
|
||||
set -x
|
||||
|
||||
## Boot entries
|
||||
mkdir /opt/init.d/
|
||||
mv /build/boot/*.sh /opt/init.d/
|
||||
@@ -1,10 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
source /build/config
|
||||
set -x
|
||||
|
||||
apt-get clean
|
||||
rm -rf /build
|
||||
rm -rf /tmp/* /var/tmp/*
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
rm -f /etc/dpkg/dpkg.cfg.d/02apt-speedup
|
||||
12
build/scripts/cleanup.sh
Normal file
12
build/scripts/cleanup.sh
Normal file
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
source /build/config
|
||||
set -x
|
||||
|
||||
|
||||
echo $MODE
|
||||
apt-get clean
|
||||
# rm -rf /build
|
||||
rm -rf /tmp/* /var/tmp/*
|
||||
# rm -rf /var/lib/apt/lists/*
|
||||
# rm -f /etc/dpkg/dpkg.cfg.d/02apt-speedup
|
||||
7
build/scripts/compile.sh
Normal file
7
build/scripts/compile.sh
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
source /build/config
|
||||
set -x
|
||||
|
||||
## Often used tools
|
||||
$minimal_apt_get_install gcc make automake libtool
|
||||
@@ -4,9 +4,7 @@ source /build/config
|
||||
set -x
|
||||
|
||||
## Install cron daemon
|
||||
$minimal_apt_get_install cron
|
||||
mkdir -p /etc/service/cron
|
||||
mv /build/runit/cron /etc/service/cron/run
|
||||
apt_get_install_permanent cron
|
||||
|
||||
## Remove useless cron entries
|
||||
# Checks for lost+found and scans for mtab
|
||||
@@ -4,7 +4,6 @@ source /build/config
|
||||
set -x
|
||||
|
||||
## Install init process
|
||||
mv /build/init /opt/
|
||||
mkdir -p /etc/container_environment
|
||||
touch /etc/container_environment.sh
|
||||
touch /etc/container_environment.json
|
||||
@@ -13,7 +13,9 @@ export INITRD=no
|
||||
mkdir -p /etc/container_environment
|
||||
echo -n no > /etc/container_environment/INITRD
|
||||
|
||||
## Update package list
|
||||
## Enable Ubuntu Universe and Multiverse.
|
||||
sed -i 's/^#\s*\(deb.*universe\)$/\1/g' /etc/apt/sources.list
|
||||
sed -i 's/^#\s*\(deb.*multiverse\)$/\1/g' /etc/apt/sources.list
|
||||
apt-get update
|
||||
|
||||
## Fix some issues with APT packages
|
||||
@@ -36,4 +38,7 @@ apt-get dist-upgrade -y --no-install-recommends
|
||||
|
||||
## Fix locale
|
||||
$minimal_apt_get_install language-pack-en
|
||||
locale-gen en_US
|
||||
locale-gen en_US
|
||||
|
||||
## Create directory for boot scripts
|
||||
mkdir /opt/init.d/
|
||||
@@ -6,8 +6,6 @@ set -x
|
||||
## Install the SSH server
|
||||
$minimal_apt_get_install openssh-server
|
||||
mkdir /var/run/sshd
|
||||
mkdir -p /etc/service/sshd
|
||||
cp /build/runit/sshd /etc/service/sshd/run
|
||||
|
||||
## Install root key
|
||||
cd /opt
|
||||
@@ -5,7 +5,5 @@ set -x
|
||||
|
||||
## Install a syslog daemon
|
||||
$minimal_apt_get_install syslog-ng-core
|
||||
mkdir /etc/service/syslog-ng
|
||||
mv /build/runit/syslog-ng /etc/service/syslog-ng/run
|
||||
mkdir -p /var/lib/syslog-ng
|
||||
sed -i "s/^\(#SYSLOGNG_OPTS=\).*$/\1\"--no-caps --default-modules=affile,afprog,afsocket,afuser,basicfuncs,csvparser,dbparser,syslogformat\"/" /etc/default/syslog-ng
|
||||
6
build/scripts/test.sh
Normal file
6
build/scripts/test.sh
Normal file
@@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
source /build/config
|
||||
set -x
|
||||
|
||||
echo $MODE
|
||||
@@ -4,7 +4,7 @@ source /build/config
|
||||
set -x
|
||||
|
||||
## Often used tools
|
||||
$minimal_apt_get_install wget curl python-pip inetutils-ping telnet sox
|
||||
$minimal_apt_get_install wget curl python-pip git inetutils-ping telnet
|
||||
|
||||
## Often used python modules
|
||||
pip install argparse
|
||||
Reference in New Issue
Block a user