Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mailinabox
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
mailinabox
Commits
ce17c12c
Commit
ce17c12c
authored
Apr 04, 2015
by
Toilal
Committed by
Joshua Tauberer
Jun 18, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use netcat to check if mailinabox webservice is available
[JT added installing netcat-openbsd in system.sh]
parent
5edaeb8c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
6 deletions
+5
-6
management.sh
setup/management.sh
+1
-4
start.sh
setup/start.sh
+2
-1
system.sh
setup/system.sh
+2
-1
No files found.
setup/management.sh
View file @
ce17c12c
...
@@ -42,8 +42,5 @@ EOF
...
@@ -42,8 +42,5 @@ EOF
chmod
+x /etc/cron.daily/mailinabox-statuschecks
chmod
+x /etc/cron.daily/mailinabox-statuschecks
# Start it. Remove the api key file first so that start.sh
# Start it.
# can wait for it to be created to know that the management
# server is ready.
rm
-f
/var/lib/mailinabox/api.key
restart_service mailinabox
restart_service mailinabox
setup/start.sh
View file @
ce17c12c
...
@@ -103,7 +103,8 @@ source setup/management.sh
...
@@ -103,7 +103,8 @@ source setup/management.sh
source
setup/munin.sh
source
setup/munin.sh
# Ping the management daemon to write the DNS and nginx configuration files.
# Ping the management daemon to write the DNS and nginx configuration files.
while
[
!
-f
/var/lib/mailinabox/api.key
]
;
do
until
nc
-z
-w
4 localhost 10222
do
echo
Waiting
for
the Mail-in-a-Box management daemon to start...
echo
Waiting
for
the Mail-in-a-Box management daemon to start...
sleep
2
sleep
2
done
done
...
...
setup/system.sh
View file @
ce17c12c
...
@@ -36,13 +36,14 @@ apt_get_quiet upgrade
...
@@ -36,13 +36,14 @@ apt_get_quiet upgrade
# * cron: Runs background processes periodically.
# * cron: Runs background processes periodically.
# * ntp: keeps the system time correct
# * ntp: keeps the system time correct
# * fail2ban: scans log files for repeated failed login attempts and blocks the remote IP at the firewall
# * fail2ban: scans log files for repeated failed login attempts and blocks the remote IP at the firewall
# * netcat-openbsd: `nc` command line networking tool
# * git: we install some things directly from github
# * git: we install some things directly from github
# * sudo: allows privileged users to execute commands as root without being root
# * sudo: allows privileged users to execute commands as root without being root
# * coreutils: includes `nproc` tool to report number of processors
# * coreutils: includes `nproc` tool to report number of processors
# * bc: allows us to do math to compute sane defaults
# * bc: allows us to do math to compute sane defaults
apt_install python3 python3-dev python3-pip
\
apt_install python3 python3-dev python3-pip
\
wget curl git
sudo
coreutils bc
\
netcat-openbsd
wget curl git
sudo
coreutils bc
\
haveged unattended-upgrades cron ntp fail2ban
haveged unattended-upgrades cron ntp fail2ban
# Allow apt to install system updates automatically every day.
# Allow apt to install system updates automatically every day.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment