Skip to content

Instantly share code, notes, and snippets.

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

Juni Yadi JuniYadi

🏠
Working from home
View GitHub Profile
@JuniYadi
JuniYadi / Dockerfile
Created September 24, 2020 18:17 — forked from shov/Dockerfile
Docker PHP 7.2 fpm with GD jpg, png suppot
FROM php:7.2-fpm
# Replace shell with bash so we can source files
RUN rm /bin/sh && ln -s /bin/bash /bin/sh
# make sure apt is up to date
RUN apt-get update --fix-missing
RUN apt-get install -y curl
RUN apt-get install -y build-essential libssl-dev zlib1g-dev libpng-dev libjpeg-dev libfreetype6-dev
@JuniYadi
JuniYadi / ubuntu-20.04-codec.md
Created September 14, 2020 08:54
Ubuntu 20.04 Codec
sudo apt update
sudo apt install libdvdnav4 libdvdread7 gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly libdvd-pkg
sudo apt install ubuntu-restricted-extras
@JuniYadi
JuniYadi / readme.md
Created September 14, 2020 07:09 — forked from ChriRas/readme.md
Set up default audio device on Ubuntu 20.04 LTS

Problem

I have a notebook connected to a port replicator. I want to use the build-in speakers and microfone and not the external ones. If I boot my notebook in my port replicator Ubuntu changes the devices to external.

Solution

  1. Find your internal speaker
pactl list short sinks
@JuniYadi
JuniYadi / react-native-ubuntu-20.04.md
Last active July 23, 2024 16:59
Install React Native in Ubuntu 20.04

Install React Native in Ubuntu 20.04

1. Install NodeJS

  • For Development Purpose using NVM
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash
# Put this file in /etc/nginx/sites-available
# Then "ln -s /etc/nginx/sites-available/aria2-nginx.conf /etc/nginx/sites-enabled"
# Then "sudo service nginx restart"
server {
listen 80;
listen [::]:80;
root /var/www/aria2; # Put your aria2 web ui here, such as AriaNg
index index.html;
server_name DOMAIN_NAME;
location / {
@JuniYadi
JuniYadi / index.js
Created June 26, 2020 11:07 — forked from amiantos/index.js
Zip Multiple Files from S3 using AWS Lambda Function
// Lambda S3 Zipper
// http://amiantos.net/zip-multiple-files-on-aws-s3/
//
// Accepts a bundle of data in the format...
// {
// "bucket": "your-bucket",
// "destination_key": "zips/test.zip",
// "files": [
// {
// "uri": "...", (options: S3 file key or URL)
@JuniYadi
JuniYadi / tree.md
Last active April 9, 2020 12:05
Tree Directory or Files

Install Ubuntu/Debian

sudo apt-get install tree

How to use

// default command
tree
@JuniYadi
JuniYadi / ffmpeg.md
Created March 11, 2020 09:14 — forked from nnx0r/ffmpeg.md
Convert video files to MP4 through FFMPEG

This is my personal list of functions that I wrote for converting mov files to mp4!

Command Flags

Flag Options Description
-codec:a libfaac, libfdk_aac, libvorbis Audio Codec
-quality best, good, realtime Video Quality
-b:a 128k, 192k, 256k, 320k Audio Bitrate
-codec:v mpeg4, libx264, libvpx-vp9 Video Codec
@JuniYadi
JuniYadi / debnode10.sh
Last active February 16, 2020 20:46
Install Node 10.x in Debian
#!/bin/bash
# Update Repository
apt-get update
# Install Curl
apt-get install curl
# Install NodeJS 10.x
curl -sL https://deb.nodesource.com/setup_10.x | bash -
@JuniYadi
JuniYadi / speedtest.sh
Last active December 16, 2020 07:46
Install Latest Speedtest (Ubuntu/Debian/centOS) - https://www.speedtest.net/apps/cli
#!/bin/bash
if [[ $EUID -ne 0 ]]; then
echo "This script must be run as root"
exit 1
fi
if [ -f /etc/debian_version ]; then
apt-get update