V2EX POST
645 subscribers
138 photos
31 videos
99 files
103K links
v2ex新贴定时推送,可按需置顶本频道然后关闭通知
Download Telegram
关于 golang 的下载文件限速功能

https://gitee.com/jameson512/wego/blob/master/util/ratelimit/ratelimit.go

这段代码中 Wait 方法里面, time.Duration(l.count)*time.Second ,

在传入的数据 count 大于 8G 的时候,int 64 会溢出,不知道有什么好的优化方案么

#ratelimit #time #count #https #gitee #com #jameson512 #wego #blob #master
github 显创建时间/fork 数/体积脚本

之前用的浏览器插件年久失修坏了,开源社区现有的各种大而全又太重了

就自己造了个油猴轻量版来用,效果如图,没有花里胡哨,就一个 span = 创建时间 /fork 数 /体积脚本

![]( https://github.com/CXXN008/github-repo-info/blob/master/preview/g1.png?raw=true)
![]( https://github.com/CXXN008/github-repo-info/blob/master/preview/g2.png?raw=true)
![]( https://github.com/CXXN008/github-repo-info/blob/master/preview/g3.png?raw=true)

有安全疑虑的可以瞟一眼代码再装,总共五六十行

PS1: 只在`仓库搜索页`、`代码搜索页`、`仓库详情页`生效

PS2: 如果 key 失效或者超过请求频率可以去 https://github.com/settings/tokens 领 key (免费,一小时 5k 次)

需者自取,传送门 https://greasyfork.org/en/scripts/454702-github-repo-info

#github #https #com #repo #info #CXXN008 #blob #master #preview #png
[nginx] 几个易混淆的术语

引个流,不知道是否可以

https://github.com/j2gg0s/j2gg0s/blob/main/20221115_nginx_%E6%98%93%E6%B7%B7%E6%B7%86%E7%9A%84%E6%9C%AF%E8%AF%AD.md

# [nginx] 几个易混淆的术语

既没有能力也没有洁癖去考古整个 nginx 相关的历史进程, 只是简单的解释几个易混淆的术语,
提高相关同学的日常使用体验.

## nginx
在 Google 中搜索 nginx 相关的内容时, 会高频的遇到两个网站:
[nginx.org]( https://nginx.org) 和 [nginx.com]( https://doc.nginx.com).

[nginx.org]() 对应开源版本的 [nginx]( https://github.com/nginx/nginx),
[nginx.com]() 对应商业版本的 [nginx plus]( https://www.nginx.com/).
两者在功能和配置上显然并不完全等价, 查询相关特性和配置时需要根据自己使用的版本的多加注意.

大部分情况下, 我们使用的都是开源版本 [nginx]().


## ingress
我是在 kubernetes(k8s) 中频繁的接触 [ingress]( https://kubernetes.io/docs/concepts/services-networking/ingress/) 这个概念的.
[ingress]() 在 k8s 中用于管理外部对集群服务的访问, 是抽象的规则,
需要具体的 [ingress controller]( https://kubernetes.io/docs/concepts/services-networking/ingress-controllers/) 来监听这些规则并完成实际的工作.

nginx 显然是 [ingress controller]() 的非常主流的选择.
[nginx]() 和 [nginx plus]() 都可以做为 [ingress controller],
官方实现在 [nginxinc/kubernetes-ingress]( https://github.com/nginxinc/kubernetes-ingress),
文档可以参考 [nginx-ingress-controller]( https://docs.nginx.com/nginx-ingress-controller/intro/overview/).
还是那句话, 注意区分那些只在 [nginx plus] 提供的功能和配置.

但是, 我们在 k8s 中使用的 nginx ingress controller 大部分时候不是上述的实现, 惊不惊喜, 意不意外.
k8s 自己基于 [nginx]() 实现了一个 ingress-controller,
即 [kubernetes/ingress-nginx]( https://github.com/kubernetes/ingress-nginx).

如果想要区分当前的部署使用的是上述三者的哪一种, 比较好的方法是观察 image:

- [nginxinc/kubernetes-ingress] 对应的是 [nginx/nginx-ingress]( https://github.com/nginxinc/kubernetes-ingress/blob/main/deployments/daemon-set/nginx-ingress.yaml#L22) 和 [nginx-plus-ingress]( https://github.com/nginxinc/kubernetes-ingress/blob/main/deployments/daemon-set/nginx-plus-ingress.yaml#L22)
- [kubenetes/ingress-nginx] 对应的是 [ingress-nginx/controller]( https://github.com/kubernetes/ingress-nginx/blob/main/charts/ingress-nginx/values.yaml#L22)

## openresty
[openresty]( https://openresty.org/en/) 是由 [agentzh]( https://github.com/agentzh) 维护的, 基于 nginx 和 LuaJIT 的反向代理和负载均衡.
我粗浅的理解就是, 古早之前, [agentzh]() 为 nginx 加入 LuaJIT 和大量三方库后, 为了快速响应一些性能和质量问题而维护的一个 nginx 版本.

当然, [nginx]() 也在很早之前支持了 lua 做为动态脚本.

#nginx #ingress #https #com #kubernetes #github #controller #plus #nginxinc #blob
关于宫崎骏先生的那些情诗

来向各位兄弟姐妹讨教一下,下面图片中的内容是出自哪本书的(或者说这是哪本书),孩子真的超想买下这本书看看

https://github.com/BigMikey-V/MyLife/blob/main/mmexport1668621941122.jpg

#本书 #https #github #com #BigMikey #MyLife #blob #main #mmexport1668621941122 #jpg
请教一行代码, use cargo_modules

https://github.com/regexident/cargo-modules/blob/main/src/main.rs#L11
第 11 行:
use cargo_modules::options::Options;
这个 cargo_modules 是表示什么,google 没搜到。

谢谢了

#cargo #modules #main #https #github #com #regexident #blob #src #rs
为什么我们不用 git 当数据库呢?

一行 sql 也没写过不知道为啥要用这玩意
blob tree grep awk 各种 pipe 倒是一点不怵
我感受不到任何 crud 比 git 更好用的(个人感受
github 就是拿 git 当数据库的, 对吧?(摆事实

#git #感受 #摆事实 #sql #blob #tree #grep #awk #pipe #不怵
厦门前端,有捞一下的吗

今年毕业,但是去年已经开始实习了,四舍五入也有一年前端经验了(
之前主要是 web3 方向的,还想再找一个 web3 相关的,或者不相关的也行,不是很想浪费 web3 经验
[简历]( https://github.com/EndureBlaze/Files/blob/main/resume.pdf)
个人网站: https://imyan.ren
GitHub: https://github.com/EndureBlaze

#web3 #https #github #com #EndureBlaze #四舍五入 #Files #blob #main #resume
请问怎么通过 blob 链接抓到原始图片资源

不太懂前端,这种链接可以获取原始图片吗,网页上显示的是一个图片
blob:https://xxx.com/6239cc21-ec1d-4e9c...

谢谢

#图片 #不太懂 #blob #https #xxx #com #6239cc21 #ec1d #4e9c #...
关于赠送 telegram 会员的价格到底取决于什么

我想赠送一年的 telegram 会员,但是发现土区的价格也并不便宜
国区:![国区]( https://github.com/SeduceQ/PicGo/blob/master/telegram/%E5%9B%BD%E5%8C%BA.jpg?raw=true)
美区:![美区]( https://github.com/SeduceQ/PicGo/blob/master/telegram/%E7%BE%8E%E5%8C%BA.jpg?raw=true)
土区:![土区]( https://github.com/SeduceQ/PicGo/blob/master/telegram/%E5%9C%9F%E5%8C%BA.jpg?raw=true)
这个赠送会员到底取决于什么,难道是因为土区汇率太低了,赠送会员增加收费了。。。

#E5% #telegram #土区 #https #github #com #SeduceQ #PicGo #blob #master
尝试收集大家的 2022

如题,大概咨询了周围的人
https://github.com/xly135846/-/blob/main/2022.md
如果不介意也分享一下,又或者从中获取到了部分力量,可以直接回答
引导的问答如下:
1.年初有立什么目标吗?完成度怎么样?
2.今年最大的收获是?其他收获呢?工作和生活上
3.对明年的自己有什么期望吗?希望能够实现什么目标?
如果有照片想添加进来,请发照片到 hundan135846@163.com

#com #收获 #照片 #https #github #xly135846 #blob #main #2022 #md
**资深前端求岗可捞 上海浦江**

天有不测风云 月有阴晴圆缺 因不可抗因素 招聘者沦为应聘者
- **多年互联网和 crypto 行业经验**
- 详细信息可查看 [在线简历]( https://github.com/jincan39/CV/blob/gh-pages/Jincan_s_LaTeX_R_sum_en.pdf) 及 [个人资料]( https://v2ex.com/member/jincan39)

`` 详聊
微信:amluY2FuMzk=
Email:amluY2FuMzlAMTYzLmNvbQ==
``

#https #com #jincan39 #阴晴圆 #招聘者 #crypto #github #CV #blob #gh
基于 markdown 文件生成网站,可以当作 blog 使用。开发语言是 GO。

功能类似于 docsify

简而言之,就是通过 go 跑了一个 server ,读取你的文件夹内的 markdown 文件,并提供 web 访问。

放个链接 [go-markdown-book]( https://github.com/hedongshu/go-markdown-book)

放两张图
![light]( https://github.com/hedongshu/go-markdown-book/blob/main/light.jpg?raw=true)
![dark]( https://github.com/hedongshu/go-markdown-book/blob/main/dark.jpg?raw=true)

#go #markdown #book #https #github #com #hedongshu #light #blob #main