Skip to content

Instantly share code, notes, and snippets.

View naagaraa's full-sized avatar
:shipit:
working from anywhere

miyuki nagara naagaraa

:shipit:
working from anywhere
View GitHub Profile
@naagaraa
naagaraa / supervisor-worker-octane.conf
Last active February 18, 2024 06:52
supervisor-worker-octane.conf
[program:SITE_DOMAIN-worker-octane]
process_name=%(program_name)s_%(process_num)02d
command=php /var/www/html/SITE_DOMAIN/artisan octane:start
directory=/var/www/html/SITE_DOMAIN
user=www-data
autostart=true
autorestart=true
startsecs=0
numprocs=2
stopwaitsecs=10
@naagaraa
naagaraa / supervisor-worker.conf
Last active February 14, 2024 15:46
supervisor-worker.conf
[program:SITE_DOMAIN-worker]
process_name=%(program_name)s_%(process_num)02d
command=php /var/www/html/SITE_DOMAIN/artisan queue:work --tries=3 --daemon
autostart=true
autorestart=true
stopasgroup=true
killasgroup=true
user=www-data
numprocs=2
redirect_stderr=true
@naagaraa
naagaraa / nginx.vhost.template.php8.2.conf
Last active June 8, 2024 17:12
nginx.vhost.template.php8.2.conf
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
# Server block for each website or application
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
@naagaraa
naagaraa / Error at Ubuntu User.md
Last active April 10, 2024 07:12
Journey My Ubuntu

UBUNTU

  • 22.06 Jammy JellyFish

this daily my problem use linux ubuntu, this solution for thats

problem 0

i don't know how to remove or clean uninstall program at linux hahaha but now i know that's

this example for platpak

@naagaraa
naagaraa / interventionImageLaravel.php
Created February 22, 2023 05:19
example how to use laravel intervention at laravel 8
<?php
namespace Modules\Admin\Http\Controllers\Achievement;
use Ramsey\Uuid\Uuid;
use Illuminate\Http\Request;
use Illuminate\Routing\Controller;
use Intervention\Image\Facades\Image;
use App\Models\AchievementRewardModel;
use App\Models\Images;
@naagaraa
naagaraa / example-laravel-export.php
Last active December 21, 2022 12:57
laravel export to separate files .xlsx store at storage. you need install laravel excel for used this command
<?php
// in controller
use App\Exports\WebTrafictExport;
use App\Models\Trafict;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
class ExportImportController extends Controller
{
public function ExportTrafict(Request $request)
@naagaraa
naagaraa / Microsoft-Docs.md
Last active April 28, 2023 07:56
Microsoft-Docs

IT Support

try make documentation for freak , and funny problem wkwkw lol.

Office

this for note me, from giodanacardillo, for office lisence problem and check.

1. Open a command prompt as Administrator
2. In the command prompt, type the following:
  * Office 2016 (32-bit) on a 32-bit version of Windows 
@naagaraa
naagaraa / server.md
Last active February 3, 2024 12:17
Setup Laravel and Nodejs Nginx Ubuntu Server

Server Prepare for Development testing

  • nodejs
  • nginx
  • laravel

setup for nodejs

you need install pm2 in your server, by the way used ubuntu 22

run nodejs with pm2 in your project

<?php
function checkbus($family = 5, $member = [])
{
if ($family == count($member)) {
sort($member);
$max_familily = 4;
// echo "this is valid data";
<?php
function vocal($string = "")
{
$string = str_split(str_replace(" ", "", strtolower($string)));
$vocal = "aiueo";
$result = [];
foreach ($string as $key => $value) {
if (str_contains($vocal, $value)) {