Skip to content

Instantly share code, notes, and snippets.

View mohammadsadeghforoughi's full-sized avatar
🐱
Focusing

Mohammad Sadegh Foroughi mohammadsadeghforoughi

🐱
Focusing
View GitHub Profile
@alikarimii
alikarimii / wireguardOverWebsocket.md
Last active April 15, 2024 19:21
Set Up a Wireguard VPN Server with WebSocket Tunneling

این آموزش مربوط به سیستم های یونیکسه.

CDN

خب اول یک دامنه یا ساب دامنه انتخاب کنید و یک A رکورد به مقدار آی پی سرور خارجی و پرت HTTPS بسازید.سی دی ان داخلی باشه که طرح رذالتو دور بزنید. باید روی SSL,CDN رو فعال کنید.

SSL

خب برای اون دامنه باید اس اس ال داشته باشید با این فایل ها fullchain.pem, privkey.pem, chain.pem, dhparam.pem آموزش گرفتن اس اس ال هم که زیاده. (dhparam- Diffie–Hellman (D-H))

NGINX

اول nginx رو روی سرور خارجی نصب کنید.

@sh-sh-dev
sh-sh-dev / DigikalaProduct.php
Last active June 13, 2024 15:45
Digikala Products Info
<?php
function digikalaProduct($PID) {
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://api.digikala.com/v1/product/$PID/");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.81 Safari/537.36");
$output = curl_exec($ch);
curl_close($ch);
return $output;