Skip to content

Instantly share code, notes, and snippets.

View jhonoryza's full-sized avatar
🏠
Working from home

fajar sp jhonoryza

🏠
Working from home
View GitHub Profile
@jhonoryza
jhonoryza / ryzen-parts.md
Last active July 19, 2023 08:13
ryzen rakitan

CPU

  1. Motherboard ASRock A520M-HVS Rp 879.999
  2. CPU Ryzen 5600G Rp 1.974.999
  3. Case Cube Gaming Stutt Rp 380.000
  4. RAM Apacer NOX DDR4 PC28800 3600MHz 16GB Dual Channel (8x2) Rp 620.000
  5. Casing Paradox Gaming Luxy Rp 375.000

Monitor 22 inch

  • valet isolate php@7.4 (untuk menset current dir menggunakan spesific php version)
  • valet isolated (list all isolated)
  • valet parked (list all parked)
  • valet park (unutk menset current dir sebagai parked)

setiap ada perubahan default php version

run command dibawah untuk mereset valet

composer global update
rm -f ~/.config/valet/valet.sock
@jhonoryza
jhonoryza / websocket.md
Last active January 17, 2024 04:20
List Websocket for Laravel

Websocket

websocket server

  1. pusher (subscription) - laravel integration builtin (event & broadcasting) - https://pusher.com/
  2. ably (subscription) - https://ably.com/blog/building-a-realtime-chat-app-with-react-laravel-and-websockets
  3. laravel websocket (free) php - (pusher compatible) https://github.com/beyondcode/laravel-websockets
  4. laravel echo server (free) nodejs - Socket.io server for Laravel Echo - https://github.com/tlaverdure/laravel-echo-server
  5. socket io (free) nodejs - https://github.com/socketio/socket.io
  6. soketi (free) nodejs - (pusher compatible) https://github.com/soketi/soketi

step to fix missing launcher in linux after install snapd application

  1. Edit the file “60x11-common_xdg_path” located at /etc/X11/Xsession.d by executing the command “sudo nano /etc/X11/Xsession.d/60x11-common_xdg_path” in terminal.
  2. Press the keys Ctrl + w and search for export XDG_DATA_DIRS. It would be somewhere around line 22, depending on the settings in your machine.
  3. Just above that line, add XDG_DATA_DIRS=/var/lib/snapd/desktop:"$XDG_DATA_DIRS"

image

@jhonoryza
jhonoryza / command.md
Created February 9, 2023 17:40
Connect to vpn or wifi from terminal

List all connections in NetworkManager:

$ nmcli con

Show information about the created VPN connection:

$ nmcli c show id [VPNConnectionName]

To connect to the L2TP VPN server from the command line:

$ nmcli c up [VPNConnectionName]

To disconnect from a VPN server, run:

@jhonoryza
jhonoryza / setup.md
Created February 4, 2023 01:55
gitlab runner setup
docker volume create gitlab-runner-config

docker run -d --name gitlab-runner --restart always \
    -v /var/run/docker.sock:/var/run/docker.sock \
    -v gitlab-runner-config:/etc/gitlab-runner \
    gitlab/gitlab-runner:latest

docker run --rm -it -v gitlab-runner-config:/etc/gitlab-runner gitlab/gitlab-runner:latest register
@jhonoryza
jhonoryza / setup.md
Created February 2, 2023 08:27
switch between php version ubuntu 20.04
# Verify PHP
php --version

# Output
PHP 8.0.13 (cli) (built: Nov 22 2021 09:50:43) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.13, Copyright (c) Zend Technologies
    with Zend OPcache v8.0.13, Copyright (c), by Zend Technologies
    
@jhonoryza
jhonoryza / setup.md
Last active January 28, 2023 16:16
web dev setup

install brew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

install php

brew install php@8.2 \
&& php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" \
&& php composer-setup.php \