Skip to content

Instantly share code, notes, and snippets.

View syofyanzuhad's full-sized avatar
🇵🇸
FREE PALESTINE

Syofyan Zuhad 🇵🇸 syofyanzuhad

🇵🇸
FREE PALESTINE
View GitHub Profile
@rebane2001
rebane2001 / glass-with-controls.html
Last active October 31, 2025 17:19
glass effect test css/svg thing (messy) - demo: https://codepen.io/rebane2001/details/OPVQXMv
<div style="position:absolute;top:-999px;left:-999px">
<svg
id="effectSvg"
width="200"
height="200"
viewBox="0 0 200 200"
xmlns="http://www.w3.org/2000/svg">
<filter id="displacementFilter4">
@jonerickson
jonerickson / deploy.yml
Created November 7, 2024 16:09
Vapor Deploy
name: Deploy Application
env:
SIDECAR_APP_NAME: ${{ secrets.SIDECAR_APP_NAME }}
SIDECAR_ACCESS_KEY_ID: ${{ secrets.SIDECAR_ACCESS_KEY_ID }}
SIDECAR_SECRET_ACCESS_KEY: ${{ secrets.SIDECAR_SECRET_ACCESS_KEY }}
SIDECAR_REGION: ${{ secrets.SIDECAR_REGION }}
SIDECAR_ARTIFACT_BUCKET_NAME: ${{ secrets.SIDECAR_ARTIFACT_BUCKET_NAME }}
SIDECAR_EXECUTION_ROLE: ${{ secrets.SIDECAR_EXECUTION_ROLE }}
VAPOR_API_TOKEN: ${{ secrets.VAPOR_API_TOKEN }}
# SETUP #
DOMAIN=example.com
PROJECT_REPO="[email protected]:example.com/app.git"
AMOUNT_KEEP_RELEASES=5
RELEASE_NAME=$(date +%s--%Y_%m_%d--%H_%M_%S)
RELEASES_DIRECTORY=~/$DOMAIN/releases
DEPLOYMENT_DIRECTORY=$RELEASES_DIRECTORY/$RELEASE_NAME
# stop script on error signal (-e) and undefined variables (-u)
@mul14
mul14 / README.md
Last active November 4, 2024 06:03
How to set MySQL timezone with timezone name?

Check current MySQL timezone:

SELECT @@global.time_zone, @@session.time_zone;

The value might be SYSTEM, UTC, or your current MySQL timezone.

If you want to change the default MySQL timezone to something else (e.g Asia/Jakarta), run this query:

SET GLOBAL time_zone = 'Asia/Jakarta';
@abir-taheer
abir-taheer / instagram-follower-following.js
Last active December 9, 2025 16:32
"This is our community, this is our family, these are our friends." https://www.youtube.com/watch?v=gk7iWgCk14U&t=425s
if (window.location.origin !== "https://www.instagram.com") {
window.alert(
"Hey! You need to be on the instagram site before you run the code. I'm taking you there now but you're going to have to run the code into the console again.",
);
window.location.href = "https://www.instagram.com";
console.clear();
}
const fetchOptions = {
credentials: "include",
@syofyanzuhad
syofyanzuhad / DependantDropdownController.php
Created September 2, 2021 07:36
Its used for laravolt/indonesia package
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
class DependentDropdownController extends Controller
{
public function provinces()
{
@syofyanzuhad
syofyanzuhad / Envoy.blade.php.md
Created July 27, 2021 07:47 — forked from nasirkhan/Envoy.blade.php.md
Deploying with Envoy

SSH Keys

SSH keys provide a more secure way of logging into a virtual private server with SSH than using a password alone. While a password can eventually be cracked with a brute force attack, SSH keys are nearly impossible to decipher by brute force alone. Generating a key pair provides you with two long string of characters: a public and a private key. You can place the public key on any server, and then unlock it by connecting to it with a client that already has the private key. When the two match up, the system unlocks without the need for a password. You can increase security even more by protecting the private key with a passphrase.

https://www.digitalocean.com/community/tutorials/how-to-set-up-ssh-keys--2

Step One—Create the RSA Key Pair

The first step is to create the key pair on the client machine (there is a good chance that this will just be your computer):

@syofyanzuhad
syofyanzuhad / mahfudzot.json
Last active July 18, 2021 08:54
Data json of mahfudzot [Fashlul Awal]
{
"1": [
{
"nomor": 1,
"arab": "مَنْ سَارَ عَلىَ الدَّرْبِ وَصَلَ",
"latin": "Man saara ‘alad darbi washala",
"arti": "Barang siapa berjalan pada jalannya sampailah ia"
},
{
"nomor": 2,
@syofyanzuhad
syofyanzuhad / FileUploader.php
Last active June 14, 2025 05:54
Laravel Trait for uploading Images / Photos, Files and Deleting Files
<?php
namespace App\Traits;
use Illuminate\Support\Facades\Storage;
trait FileUploader
{
public function uploadFile($request, $data, $name, $inputName = 'files')
{
@danielwetan
danielwetan / nodejs-cicd-github-actions.md
Last active November 13, 2025 15:12
Deploy Node.js to VPS using Github Actions

Deploy Node.js to VPS using Github Actions

Steps to deploy Node.js to VPS using PM2 and Github Actions

1. Clone repo to VPS folder