39 lines
948 B
Bash
Executable File
39 lines
948 B
Bash
Executable File
#!/bin/bash
|
|
template templates/hosthostname ./host_vars
|
|
t
|
|
# ------ create user 4server
|
|
|
|
|
|
# ------ disable root user and login
|
|
|
|
|
|
# ----- install nabula
|
|
echo "prsync nebula bin"
|
|
prsync -h "$hosts_file" -avz ./templates/nebula/nebula /4server/nebula
|
|
rex doas mv /4server/nebula /usr/bin/
|
|
|
|
rex doas mkdir -p /etc/nebula
|
|
rex doas chmod 700 /etc/nebula
|
|
|
|
template templates/nebula/nebula.yml /etc/nebula/config.yml ./host_vars
|
|
template templates/nebula/host.key /etc/nebula/host.key ./host_vars
|
|
template templates/nebula/host.crt /etc/nebula/host.crt ./host_vars
|
|
|
|
rex doas chmod 700 /etc/nebula
|
|
|
|
template templates/init.d/nebula /etc/init.d/nebula ./host_vars/
|
|
rex doas chmod 0755 /etc/init.d/nebula
|
|
rex doas chown root:root /etc/init.d/nebula
|
|
rex doas rc-update add nebula default
|
|
rex doas rc-service nebula restart
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#! ----------- install ufe
|
|
- ssh, 8080 only on nebula
|
|
- only 80, 443 to the world
|