自分のメモのために作りました。
W_OUT
= Output width
W_IN
= Input width
F_W
= Filter width(kernel size)
#!/bin/bash | |
cat /etc/fstab | sed /swap/d | tee /etc/fstab | |
swapoff -a | |
sed -i 's/127\.0\.0\.53/1.1.1.1/g' /etc/resolv.conf | |
cat <<EOF | sudo tee /etc/modules-load.d/containerd.conf | |
overlay | |
br_netfilter | |
EOF |
from playwright.async_api import async_playwright | |
from bs4 import BeautifulSoup | |
import asyncio | |
import base64 | |
import aiohttp | |
import aiofiles | |
LABEL = input("ラベル名: ") | |
TYPE = input("タイプ: ") |
from torch.utils.data import Dataset, DataLoader | |
from torchvision import transforms | |
IMAGE_DIR = Path("images") | |
class MyDataset(Dataset): | |
def __init__(self, transform=None): | |
self.transform = transform |
INTERFACE=eth0 | |
clear | |
echo "[+] checking packages" && sudo apt-get update > /dev/null && sudo apt-get install wireguard qrencode jq -y > /dev/null && | |
echo "[+] creating keypars" && rm -rf /etc/wireguard/keypars && mkdir /etc/wireguard/keypars && | |
wg genkey | sudo tee -a /etc/wireguard/keypars/server.key > /dev/null | |
sudo cat /etc/wireguard/keypars/server.key | wg pubkey | tee -a /etc/wireguard/keypars/server.pub > /dev/null | |
wg genkey | tee -a /etc/wireguard/keypars/client.key > /dev/null | |
sudo cat /etc/wireguard/keypars/client.key | wg pubkey | tee -a /etc/wireguard/keypars/client.pub > /dev/null | |
echo "[+] creating config files" | |
sudo cat <<EOF > /etc/wireguard/wg0.conf |
cat <<EOF > user-data.yml | |
ssh_pwauth: true | |
password: sample | |
EOF | |
wget https://download.rockylinux.org/pub/rocky/9/images/x86_64/Rocky-9-GenericCloud.latest.x86_64.qcow2 | |
sudo virt-install --name vm \ | |
--memory 2048 \ | |
--vcpus 2 \ |
#!/bin/bash | |
# <UDF name="token" label="The kubeadm join token to use for cluster init"> | |
# <UDF name="hostname" label="Hostname to use, should match linode label"> | |
# <UDF name="endpoint" label="The kube-apiserver endpoint to use"> | |
# <UDF name="wgapipeers" label="A space separated list of WG Public Keys and their IPs for the API server"> | |
# <UDF name="hosts" label="The hosts to be added to /etc/hosts"> | |
set -e | |
set -x | |
( |
#!/bin/bash | |
read -p "Build with master node? (y/n): " MASTER_NODE | |
read -p "What are you using kubernetes version? (example v1.30): " KUBERNETES_VERSION | |
# Install Containerd | |
cat <<EOF | sudo tee /etc/modules-load.d/containerd.conf | |
overlay | |
br_netfilter |
log syslog all; | |
router id 172.16.1.1; | |
protocol bgp { | |
import all; | |
export all; | |
local as 65001; | |
neighbor 172.16.70.12 as 65002; | |
} |
"use server"; | |
import axios from "axios"; | |
const ExchangeCodePage = ({ searchParams }: { searchParams: { code: string } }) => { | |
const code = searchParams.code; | |
console.log(code); | |
const res = await axios.post( | |
"/api/auth/cbauth", | |
{ |