This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Source https://paul.grozav.info/2018/04/13/artix-linux/ | |
# By now you should have done those steps: | |
# 1. You boot the iso, then check that you have a working internet connection(ping google.com or something). | |
# 2. You use fdisk to partition you hdd. I created only one partition | |
# 3. You format it using mkfs.ext4 | |
# 4. And mount it to /mnt: mount /dev/sda1 /mnt | |
# 5. I’ve commented all servers in /etc/pacman.d/mirrorlist and added: https://mirrors.dotsrc.org/artix-linux/repos/$repo/os/$arch. | |
echo "Configuring Artix linux..." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Source https://paul.grozav.info/2018/04/13/artix-linux/ | |
# By now you should have done everything from `Configure Artix Linux Part 1`: | |
# Set timezone: | |
ln -sf /usr/share/zoneinfo/Europe/Bucharest /etc/localtime | |
hwclock --systohc | |
# Set locale | |
echo "LANG=en_US.UTF-8" > /etc/locale.conf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
timedatectl set-ntp true | |
timedatectl set-timezone Europe/Bucharest | |
fdisk /dev/sda | |
######################################## | |
n 1G pentru /boot /dev/sda1 | |
a - Flag it as bootable | |
n - 4G pentru swap /dev/sda3 | |
n - 70G pentru / /dev/sda2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//xcr.c | |
//cc -o xcr $(pkg-config --cflags --libs cairo xcb xcb-icccm) xcr.c -lcairo -lxcb -lxcb-icccm | |
#include <stdlib.h> | |
#include <string.h> | |
#include <cairo.h> | |
#include <cairo-xcb.h> | |
#include <xcb/xcb.h> | |
#include <xcb/xcb_image.h> | |
#include <xcb/xcb_aux.h> | |
#include <xcb/xcb_icccm.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install docker-ce on debian | |
# Run as root | |
# Change this to your user to be added to docker group | |
user="chreniuc" | |
apt-get update | |
apt-get install \ | |
apt-transport-https \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Script to start a openvpn server | |
IP="1.1.1.1" # Public ip | |
PORT="7777" # External port | |
USER="chreniuc" # User for vpn | |
OPEN_VPN_MOUNT="$(pwd)/home_test/" # Where open vpn should store all its data. This should exist. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Restart the networking daemon: | |
# systemctl restart networking | |
# Shutdown an interface: ifdown eth0 | |
# Enable an interface: ifup eth0 | |
# The loopback network interface (localhost) | |
# Localhost | |
auto lo | |
iface lo inet loopback |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install ufw: | |
apt install ufw | |
# Set rules back to default: | |
ufw default deny incoming | |
ufw default allow outgoing | |
# Allow ssh: |