etc
Jun 11, 2015
UNIX的/etc目录 早期系统/bin是用来存放程序(可执行二进制文件)的,然后有了/dev用来存放设备文件,和/lib用来存放库文件。/usr目录很早也有了,首先用来存放用户数据,后来也放一些用户级的/bin和/lib,man形式的用户手册也存放在此。 …
使用gitolite自建git服务器
Jun 09, 2023
服务器环境如下: ➜ ~ neofetch `.::///+:/-. --///+//-:`` pi@raspi2b `+oooooooooooo: `+oooooooooooo: ---------- /oooo++//ooooo: ooooo+//+ooooo. OS: Raspbian GNU/Linux 11 (bullseye) armv `+ooooooo:-:oo- +o+::/ooooooo: Host: Raspberry Pi 2 Model B Rev 1.1 `:oooooooo+`` `.oooooooo+- Kernel: 6.1.21-v7+ `:++ooo/. :+ooo+/.` Uptime: 1 hour, 53 mins ...` `.----.` ``.. Packages: 624 (dpkg) .::::-``:::::::::.`-:::-` Shell: zsh 5.8 -:::-` .:::::::-` `-:::- Terminal: /dev/pts/1 `::. `.--.` `` `.---.``.::` CPU: BCM2835 (4) @ 1.000GHz .::::::::` -::::::::` ` Memory: 70MiB / 921MiB .::` .:::::::::- `::::::::::``::. -:::` ::::::::::. ::::::::::.`:::- :::: -::::::::. `-:::::::: :::: -::- .-:::-.``....``.-::-. -::- .. `` .::::::::. `..`.. -:::-` -::::::::::` .:::::` :::::::` -::::::::::` :::::::. .::::::: -::::::::. :::::::: `-:::::` ..--.` ::::::. `...` `...--..` `...` .:::::::::: `.-::::-` 添加git用户 服务器添加git用户并设置密码 …
stuffdebianraspissh树莓派bullseyeraspbianopensslgitgitoliteed25519
使用gitea自建git服务
May 17, 2023
安装git和sqlite apt install git sqlite3 -y 安装gitea 下载地址在此 https://dl.gitea.com/gitea/ wget -O gitea https://dl.gitea.com/gitea/1.19.3/gitea-1.19.3-linux-amd64 chmod +x gitea mv gitea /usr/local/bin/gitea 添加git用户 adduser --system --group --disabled-password --shell /bin/bash --home /home/git --gecos 'Git User' git 新建目录 mkdir -p /var/lib/gitea/{custom,data,log} chown -R git:git /var/lib/gitea/ chmod -R 750 /var/lib/gitea/ mkdir /etc/gitea chown root:git /etc/gitea chmod 750 /etc/gitea chmod 640 /etc/gitea/app.ini export GITEA_WORK_DIR=/var/lib/gitea/ 设置systemd服务 ## 备份链接 https://0x8.net/res/gitea.service wget https://raw.githubusercontent.com/go-gitea/gitea/main/contrib/systemd/gitea.service cp gitea.server /etc/systemd/system/gitea.service sudo systemctl enable gitea sudo systemctl start gitea 配置gitea 通过http://ip:3000来访问gitea web进行初始配置。 …
将博客从Typecho转移至Gor
Jul 20, 2015
缘由 VPS快到期了,不想继续维护,太累,并且香港VPS价格也不菲。 于是打算选择一个静态博客平台,原来用过的不少:jekyll,hexo,gor,pelican,最后决定Gor …
stuffGoogleGitgorGithubVPSMySQLMarkdowngolangBlogtypechophpsqlnotepad++
使用speedtest-cli测试带宽
Mar 26, 2015
安装speedtest-cli 安装speedtest-cli方法如下: sudo apt-get install python-pip sudo pip install speedtest-cli 或 pip install git+https://github.com/sivel/speedtest-cli.git 或 git clone https://github.com/sivel/speedtest-cli.git python speedtest-cli/setup.py install 或 wget -O speedtest-cli https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest_cli.py chmod +x speedtest-cli 或 curl -Lo speedtest-cli https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest_cli.py chmod +x speedtest-cli 使用speedtest-cli root@MyUbuntuCloud:~# speedtest-cli -h usage: speedtest-cli [-h] [--bytes] [--share] [--simple] [--list] [--server SERVER] [--mini MINI] [--source SOURCE] [--timeout TIMEOUT] [--version] Command line interface for testing internet bandwidth using speedtest.net. -------------------------------------------------------------------------- https://github.com/sivel/speedtest-cli optional arguments: -h, --help show this help message and exit --bytes Display values in bytes instead of bits. Does not affect the image generated by --share --share Generate and provide a URL to the speedtest.net share results image --simple Suppress verbose output, only show basic information --list Display a list of speedtest.net servers sorted by distance --server SERVER Specify a server ID to test against --mini MINI URL of the Speedtest Mini server --source SOURCE Source IP address to bind to --timeout TIMEOUT HTTP timeout in seconds. Default 10 --version Show the version number and exit 以下为两则实例: …
使用SSH密匙登录Github
Sep 03, 2013
相较于旧的RSA,更加推荐ED25519 $ ssh-keygen -t ed25519 -C "your_email@example.com" 生成ssh密匙文件 ssh-keygen -t rsa -C "user@domain.com" 接下来会提示输入密码,推荐自定义密码,当然也可以置空 Enter passphrase(empty for no passphrase): Enter same passphrase again: 完成后会在用户目录下的.ssh文件夹中新建id_rsa与is_rsa.pub两个文件。 …