CA cert
> System > Certificates
> [Add new]
Name: ca
Country: UA
Common name: ca
Key size: 4096
Key Usage: key cert. sign
CA cert
> System > Certificates
> [Add new]
Name: ca
Country: UA
Common name: ca
Key size: 4096
Key Usage: key cert. sign
$ pacman -S openvpn easy-rsa
$ cp -a /etc/easy-rsa/. /etc/easy-rsa-clientnet/
$ cd /etc/easy-rsa-clientnet/
$ export EASYRSA=$(pwd)
$ easyrsa init-pki
$ easyrsa build-ca nopass
$ easyrsa gen-req server nopass
$ easyrsa sign-req server server
Scenario
/boot
is to small to contain ISO fileWorkaround
dd
your ISO into that partitionwget https://boot.netboot.xyz/ipxe/netboot.xyz.lkrn -O /boot/netboot.xyz.lkrn
nano /etc/grub.d/40_custom
#/etc/grub.d/40_custom
menuentry "netboot.xyz.lkrn" {
linux16 (hd0,msdos1)/netboot.xyz.lkrn # /boot is (hd0,msdos1) drive
}
#
# One of
# ! /bin/bash | |
# Build of php-zts OR php (if remove --enable-maintainer-zts flag) as second php into /usr/local/php/php-zts7.2.1 | |
# Based on | |
# https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=php-zts | |
mkdir -p /root/aur-php/ | |
cd /root/aur-php/ | |
curl -O https://aur.archlinux.org/cgit/aur.git/snapshot/php-zts.tar.gz | |
tar -xzf php-zts.tar.gz -C patch | |
curl -O -L https://php.net/distributions/php-7.2.1.tar.xz |
### Install BIND | |
# https://wiki.archlinux.org/index.php/BIND | |
pacman -S bind | |
### Configure named.conf | |
# cp /etc/named.conf /etc/named.conf.bak | |
# nano /etc/named.conf | |
# diff /etc/named.conf.bak /etc/named.conf | |
9c9 | |
< // listen-on-v6 { any; }; | |
--- |
Example shows 2 domains in 1 IP address && 1 postfix instance. All redirected to Gmail.
First domain used as myhostname
and is main domain. Others is virtual_alias_domains
Dovecot configured to use passwd database without IMAP && POP3. SMTP auth only
Gmail configured to send emails from our domains (using smtp TLS port 25).
DNS && SPF && PTR records. Example provided.
Brief config overview
Domains /etc/postfix/main.cf
# GRUB loading. | |
# Welcome to GRUB! | |
# | |
# error: file `/boot/grub/i386-pc/normal.mod` not found. | |
# Entering rescue mode... | |
grub rescue> ls | |
hd(0) (hd0,msdos1) | |
grub rescue> set | |
cmdpath=(hd0) | |
prefix=(hd0,msdos1)/boot/grub |
#!/bin/bash | |
## SSH Check | |
if [ -n "$SSH_CONNECTION" ] && [ "$SHLVL" == "1" ]; then | |
## pacman -S pacman-contrib | |
## https://unix.stackexchange.com/questions/119126 | |
stat_mem=$(free -m | awk 'NR==2{printf "%s/%sMB (%.2f%%)\n", $3,$2,$3*100/$2 }') | |
stat_disk=$(df -h | awk '$NF=="/"{printf "%d/%dGB (%s)\n", $3,$2,$5}') | |
stat_cpu=$(top -bn1 | grep load | awk '{printf "%.2f\n", $(NF-2)}') | |
echo -e -n " Date : `date +"%A, %e %B %Y, %r"` | |
Hostname : `hostname` |
#!/bin/bash | |
set -e | |
# Prerequirements | |
# brew install gcc (gmp libmpc mpfr isl) | |
# copy /usr/lib && /usr/include from arch linux into your CC_ROOT. | |
# /usr/local/linux/usr/include | |
# /usr/local/linux/usr/lib | |
# /usr/local/linux/usr/local/include | |
# arch linux is target enviroment for this cross compiler | |
# x86_64 binutils && gcc |