2025/11/26 生成 raritanのminb更新
This file contains hidden or 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
| [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = 'High')] | |
| param() | |
| $ErrorActionPreference = 'Stop' | |
| function Test-IsAdministrator { | |
| $currentIdentity = [Security.Principal.WindowsIdentity]::GetCurrent() | |
| $principal = New-Object Security.Principal.WindowsPrincipal($currentIdentity) | |
| return $principal.IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator) | |
| } |
This file contains hidden or 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 | |
| # バックアップ中の unattended-upgrade 抑止制御 | |
| # Usage: bareos-apt-inhibit.sh lock|unlock | |
| LOCKDIR="/run/bareos-apt-inhibit" | |
| LOCKFILE="${LOCKDIR}/lock" | |
| COUNTFILE="${LOCKDIR}/count" | |
| mkdir -p "$LOCKDIR" |
This file contains hidden or 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
| #!/usr/bin/env bash | |
| set -euo pipefail | |
| usage() { | |
| cat <<'USAGE' | |
| Usage: | |
| sudo ./truenas_bareos_ro_clone.sh \ | |
| --truenas-host <host> \ | |
| --truenas-user <ssh_user> \ | |
| --src-dataset <pool/dataset> \ |
許可されていないURL
CPU: Intel Corei 9 13900K
CPU cooler: DeepCool Assassin III (?
M/B: MSIマザーボード MAG Z790 TOMAHAWK WIFI
RAM: DDR5 64GB (?
SSD: WD Black 2TB
GPU: RTX 4090 (既存
PW : MSI MPG A1000G PCIE5 1000w (既存
- CPU: Intel Core i7-11700K
- RAM: 32GB (16GBx2) 3200MHz
- SSD 0: WDC WDS500G2B-A-00SM50
- SSD 1: Micron_1100_MTFDDAK1T0TBN
- SSD 2: WDC WDS960G2G0C-00AJM0
- GPU 0: iGPU Intel UHD Graphics 750
- GPU 1: dGPU NVIDIA GeForce RTX 4090
各種エンコードスクリプトはD&Dか引数にエンコードしたいファイルを指定すればエンコードされる
This file contains hidden or 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
| <?php | |
| //$ composer require mpyw/co:^1.5 | |
| require __DIR__ . '/vendor/autoload.php'; | |
| use mpyw\Co\Co; | |
| use mpyw\Co\CURLException; | |
| function curl($url, $ops = []) { | |
| $ch = curl_init(); | |
| curl_setopt_array($ch, |
Google Driveの大きいファイルを直接ダウンロードするコマンド
予め公開範囲をリンクを知っているユーザー全員にしておく(特にG Suiteは手動で変更する必要あり)
FILE_ID=
FILE_NAME=
curl -sc /tmp/cookie "https://drive.google.com/uc?export=download&id=${FILE_ID}" > /dev/null
CODE="$(awk '/_warning_/ {print $NF}' /tmp/cookie)"
curl -Lb /tmp/cookie "https://drive.google.com/uc?export=download&confirm=${CODE}&id=${FILE_ID}" -o ${FILE_NAME}
NewerOlder