Skip to content

Instantly share code, notes, and snippets.

View pmventura's full-sized avatar
🎯
Focusing

Paul Ventura pmventura

🎯
Focusing
View GitHub Profile
Name: Flash
Serial: eNrzzU/OLi0odswsqnHLSSzOqDGoca7JKCkpsNLXLy8v1ytJTczVLUotKNFLzs8FAJHYETc=
if anyone wants to thank ETH: 0x527c2aB55b744D6167dc981576318af96ed26676
Thank you!
@pmventura
pmventura / clean_code.md
Created August 19, 2020 14:58 — forked from wojteklu/clean_code.md
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@pmventura
pmventura / installation_file
Last active April 30, 2020 05:45
m-otf local server installation
# Dependencies for linux ubuntu
sudo apt-get update
sudo apt install openssh-server
# Dependecy for mysqlclient
sudo apt-get install libmysqlclient-dev
# Installation for backend
sudo apt install git
@pmventura
pmventura / docker_install_on_ubuntu
Created May 28, 2018 09:32
How to install docker in ubuntu instance
1. sudo apt-get update
2. sudo apt-get install python-dev python-pip git docker.io
3. sudo curl -L https://github.com/docker/compose/releases/download/1.21.2/docker-compose-$(uname -s)-$(uname -m) -o /usr/local/bin/docker-compose
4. sudo chmod +x /usr/local/bin/docker-compose
1. Add in the "predis/predis": "~1.0" and "illuminate/redis": "5.4.*" packages to your lumen project
2. Add in the service provider of redis to config file of lumen
3. Add in the env variable of Redis to env file
4. Add in the Facade of Redis in your controller you'll going to use
NOTE:
1. Use Redis facade not Cache
2. You don't need to take care about the configuration, by the default, the database configuration will look for the laravel vendor package /vendor/laravel/lumen-framework/config/database.php
@pmventura
pmventura / aws_pyspark_installation
Last active April 25, 2018 08:45
How to install pyspark to AWS Ec2 instance
PySpark Installation on AWS EC2
1. Launch an aws ubuntu instance
2. sudo apt-get update
3. sudo apt install python3-pip
4. pip3 install jupyter
@pmventura
pmventura / Sentry.MD
Last active July 27, 2017 03:00
Sentry installation on Lumen

Steps:

Step 1: Install the laravel/lumen-framework packaged on your lumen

Step 2: Add in the Sentry Service provider to your bootstrap/app.php

$app->register(Sentry\SentryLaravel\SentryLumenServiceProvider::class);

Step 3: Create a file in your config/sentry.php and this code below