Skip to content

Instantly share code, notes, and snippets.

View buonzz's full-sized avatar

Darwin Biler buonzz

View GitHub Profile
@buonzz
buonzz / awesome-windows.md
Last active April 20, 2024 13:17
Awesome Windows
@buonzz
buonzz / compile_php.sh
Created March 21, 2020 15:24
Compiling PHP
# extensions
sudo apt-get install \
libxml2-dev \
libcurl4-openssl-dev \
libjpeg-dev \
libpng-dev \
libxpm-dev \
libmysqlclient-dev \
libpq-dev \
libicu-dev \
@buonzz
buonzz / aws_api_gateway.md
Last active February 18, 2024 16:21
AWS API Gateway

REST vs HTTP API

Choose REST APIs if you need features such as API keys, per-client throttling, request validation, AWS WAF integration, or private API endpoints. Choose HTTP APIs if you don't need the features included with REST APIs

HTTP Proxy Integrations w/ API key

  • Create new resource: method is ANY resource with {proxy+} as path
  • In method details, choose HTTP
  • in http method: ANY
  • in Endpoint URL: https://yourapi.example.com/path/{proxy} note that you cannot use root path here /, it has to be some subpath
  • ensure "HTTP proxy integration" is checked
  • click Save
@buonzz
buonzz / uninstall-gui.sh
Created February 20, 2016 14:47
raspbian - uninstall gui
sudo apt-get --purge remove x11-*
sudo apt-get --purge autoremove
@buonzz
buonzz / tomcat.sh
Last active April 13, 2023 17:37
installing tomcat 8 in Ubuntu 14
# there is a better setup on this article https://www.digitalocean.com/community/tutorials/how-to-install-apache-tomcat-8-on-ubuntu-14-04
# http://www.mkyong.com/nginx/nginx-apache-tomcat-configuration-example/
sudo apt-get update
sudo apt-get install default-jdk
sudo groupadd tomcat
sudo useradd -s /bin/false -g tomcat -d /opt/tomcat tomcat
wget http://mirror.rise.ph/apache/tomcat/tomcat-8/v8.0.30/bin/apache-tomcat-8.0.30.tar.gz
sudo tar xvzf apache-tomcat-8.0.30.tar.gz
@buonzz
buonzz / json_extract_mysql_5.6.sql
Created July 11, 2022 04:07
json extract mysql 5.6
DELIMITER $$
DROP function if exists json_extract_c$$
CREATE FUNCTION json_extract_c(
details TEXT,
required_field VARCHAR (255)
) RETURNS TEXT CHARSET utf8mb4
DETERMINISTIC
NO SQL
BEGIN
DECLARE search_term, val TEXT;
@buonzz
buonzz / docker-cheatsheet.sh
Last active March 6, 2022 11:18
docker-cheatsheet
# install it
curl -sSL https://get.docker.com/ | sh
# ubuntu 16 + mounter folder in volume
https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-docker-ce-1
https://docs.docker.com/compose/install/
https://linuxconfig.org/how-to-move-docker-s-default-var-lib-docker-to-another-directory-on-ubuntu-debian-linux
# if you are using docker other than root
sudo usermod -aG docker <user>
@buonzz
buonzz / add_service.php
Created August 24, 2014 01:56
add service provider in laravel dynamically
App::register('MyApp\Providers\MyServiceProvider');
@buonzz
buonzz / update_java.sh
Last active May 24, 2021 21:22
update java 7 to 8 Centos
sudo yum remove java-1.7.0-openjdk
cd ~
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \
"http://download.oracle.com/otn-pub/java/jdk/8u91-b14/jre-8u91-linux-i586.rpm"
sudo yum localinstall jre-8u91-linux-i586.rpm
rm ~/jre-8u91-linux-i586.rpm
@buonzz
buonzz / Install-Bamboo-in-Ubuntu-18.sh
Last active April 3, 2021 03:59
Install Bamboo in Ubuntu 18
sudo apt update
sudo apt install openjdk-8-jdk openjdk-8-jre
wget https://www.atlassian.com/software/bamboo/downloads/binary/atlassian-bamboo-7.0.3.tar.gz
cat >> /etc/environment <<EOL
JAVA_HOME= /usr/lib/jvm/java-8-openjdk-amd64
JRE_HOME=/usr/lib/jvm/java-8-openjdk-amd64/jre
EOL
tar xvzf atlassian-bamboo-7.0.3.tar.gz