sysctl -w fs.file-max=12000500
sysctl -w fs.nr_open=20000500
# Set the maximum number of open file descriptors
ulimit -n 20000000
# Set the memory size for TCP with minimum, default and maximum thresholds
sysctl -w net.ipv4.tcp_mem='10000000 10000000 10000000'
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"id": "157", | |
"nama": "Al-Amanah", | |
"nspp": "510032061290", | |
"alamat": "Pajaten Ds. Pasirhuni.", | |
"kab_kota": 1171 | |
}, | |
{ | |
"id": "158", |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
global | |
log /dev/log local0 | |
log /dev/log local1 notice | |
chroot /var/lib/haproxy | |
stats socket /run/haproxy/admin.sock mode 660 level admin | |
stats timeout 30s | |
user haproxy | |
group haproxy | |
daemon | |
maxconn 2048 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"crypto/rand" | |
"crypto/rsa" | |
"crypto/sha256" | |
"crypto/x509" | |
"encoding/base64" | |
"encoding/pem" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// gist for https://stackoverflow.com/a/67714404/2301224 | |
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatefulWidget { | |
@override | |
_MyAppState createState() => _MyAppState(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# install | |
composer require mpdf/mpdf | |
composer require mpdf/qrcode | |
# load qrcode library | |
$qrCode = new Mpdf\QrCode\QrCode("text to be generate here"); | |
$output = new Mpdf\QrCode\Output\Png(); | |
# generate base64 image qrcode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); | |
class Exporter extends CI_Controller { | |
public function __construct(){ | |
parent::__construct(); | |
} | |
public function index(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# tuned configuration for PostgresSQL servers | |
# /usr/lib/tuned/postgres-db-server/tuned.conf | |
# | |
[cpu] | |
force_latency=1 | |
governor=performance | |
energy_perf_bias=performance | |
min_perf_pct=100 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void send() async { | |
await http.post( | |
Uri.parse('https://fcm.googleapis.com/fcm/send'), | |
headers: <String, String>{ | |
'Content-Type': 'application/json', | |
'Authorization': 'key=$serverToken', | |
}, | |
body: jsonEncode( | |
<String, dynamic>{ | |
'notification': <String, dynamic>{ |
NewerOlder