Skip to content

Instantly share code, notes, and snippets.

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

iBet7o iBet7o

🏠
Working from home
View GitHub Profile
@fhdalikhan
fhdalikhan / Dockerfile
Last active September 24, 2024 21:57
Dockerfile for PHP 7.4 FPM Alpine
FROM php:7.4-fpm-alpine
WORKDIR /var/www/html
# Setup GD extension
RUN apk add --no-cache \
freetype \
libjpeg-turbo \
libpng \
freetype-dev \
Edit '/etc/sysconfig/jenkins' and add 'prefix=/jenkins' to 'JENKINS_ARGS'
**************************************************************************
JENKINS_ARGS="--prefix=/jenkins"
Comment out the default server config in '/etc/nginx/nginx.conf'
and create following file
'/etc/nginx/conf.d/domain.conf'
*************************************************
@samrocketman
samrocketman / libimobiledevice_ifuse_Ubuntu.md
Last active July 3, 2024 07:05
On Ubuntu 16.04, since iOS 10 update, libimobiledevice can't connect to my iPhone. This is my attempt to document a fix.

Why this document?

I upgraded my iPhone 5s to iOS 10 and could no longer retrieve photos from it. This was unacceptable for me so I worked at achieving retrieving my photos. This document is my story (on Ubuntu 16.04).

The solution is to compile libimobiledevice and ifuse from source.

Audience

Who is this guide intended for?

@nicksantamaria
nicksantamaria / fork-example.php
Created October 20, 2016 22:35
Example: Parallel processing in PHP using pcntl_fork()
<?php
/**
* @file
* Basic demonstration of how to do parallel threads in PHP.
*/
// This array of "tasks" could be anything. For demonstration purposes
// these are just strings, but they could be a callback, class or
// include file (hell, even code-as-a-string to pass to eval()).
@dreikanter
dreikanter / encrypt_openssl.md
Last active August 26, 2024 14:24 — forked from crazybyte/encrypt_openssl.txt
File encryption using OpenSSL

Symmetic encryption

For symmetic encryption, you can use the following:

To encrypt:

openssl aes-256-cbc -salt -a -e -in plaintext.txt -out encrypted.txt

To decrypt:

@fschabmeyer
fschabmeyer / howto_install_shrewsoft_ike_cli_linux.md
Created January 20, 2016 22:31
Installation and Configuration of Shrewsoft IKE without GUI under Debian
@javiereguiluz
javiereguiluz / gist:ec86ff09c05eabac492d
Last active August 29, 2015 14:17
Symfony en 1 minuto

Linux y Mac OS X

# (30 segundos) Instalar el Instalador de Symfony
$ sudo curl -LsS http://symfony.com/installer -o /usr/local/bin/symfony
$ sudo chmod a+x /usr/local/bin/symfony

# (10 segundos) Crear un nuevo proyecto Symfony
$ symfony new nombre_proyecto
@hofmannsven
hofmannsven / README.md
Last active August 30, 2024 10:34
Git CLI Cheatsheet
@atenni
atenni / README.md
Last active September 14, 2024 02:04
How to permalink to a gist's raw file

Problem: When linking to the raw version of a gist, the link changes with each revision.

Solution:

To return the first file from a gist: https://gist.github.com/[gist_user]/[gist_id]/raw/

To get a file from multi–file gist: https://gist.github.com/[gist_user]/[gist_id]/raw/[file_name]

@aknosis
aknosis / calendar.twig
Created October 22, 2012 15:52
Table based calendar only using Twig
{#
time can be any string acceptable by http://www.php.net/strtotime, the
template will output that time's month.
If you don't want to pass in a date you can set time like this:
{% set time = "now"|date("U") %}
{% set time = "December 2012"|date("U") %}
How ever you want to output items onto the calendar is a different issue,
but I'd assume pushing everything into an array numerically indexed by that day: