Skip to content

Instantly share code, notes, and snippets.

View cleberjsantos's full-sized avatar
🐍 00110000 01100110 01100110 01110011 01100101 01100011

Cleber J Santos cleberjsantos

🐍 00110000 01100110 01100110 01110011 01100101 01100011
View GitHub Profile
#EXTM3U
#PLAYLISTV: pltv-logo="https://s15.postimg.cc/nmizpp2qj/Slide1.jpg" pltv-name="JuniorTVOnline" pltv-description=TV ONLINE para PlaylisTV/IPTV" pltv-cover="https://s15.postimg.cc/nmizpp2qj/Slide1.jpg" pltv-author="JuniorTVOnline" pltv-site="" pltv-email="JuniorTVOnline" pltv-phone="JuniorTVOnline.
#EXTINF:-1 tvg-id="" tvg-name="Liga" tvg-logo="" tvg-shift="0" group-title="Filmes",Liga da Justiça
https://x.filmes.click/m0/d/791373-720p.mp4
############################### ABERTOS #####################################
@cleberjsantos
cleberjsantos / varnishlog-examples.sh
Created October 30, 2019 09:58 — forked from cupracer/varnishlog-examples.sh
varnishlog examples (version 4.x)
# filter by request host header
varnishlog -q 'ReqHeader ~ "Host: example.com"'
# filter by request url
varnishlog -q 'ReqURL ~ "^/some/path/"'
# filter by client ip (behind reverse proxy)
varnishlog -q 'ReqHeader ~ "X-Real-IP: .*123.123.123.123"'
# filter by request host header and show request url and referrer header
@cleberjsantos
cleberjsantos / gcs.py
Created August 20, 2019 15:57
Using Google Cloud Storage API client library to store data on Google infrastructure
""" Using: google-cloud-storage """
import os
from google.cloud import storage
# https://cloud.google.com/storage/docs/authentication#generating-a-private-key
os.environ['GOOGLE_APPLICATION_CREDENTIALS'] = 'PATH TO YOUR FILE JSON'
client = storage.Client()
# https://console.cloud.google.com/storage/browser/[bucket-id]/
@cleberjsantos
cleberjsantos / tmux-cheatsheet.markdown
Created August 7, 2019 10:27 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@cleberjsantos
cleberjsantos / k8s-tips.md
Created August 6, 2019 13:42 — forked from teonivalois/k8s-tips.md
A few kubernetes tips for those that are still learning

K8S Tips

A set of interesting tips for making the kuberenetes usage a bit more productive.


Quickly creating resources

With the --dry-run argument we can collect the object that will be sent, but without actually sending it. If combined with -o yaml we can print the yaml version of the object.

Also consider redirecting the output of the following commands to a file, like the following:

@cleberjsantos
cleberjsantos / tmux.md
Created August 1, 2019 12:44 — forked from Bekbolatov/tmux.md
Clean tmux cheat-sheet

Clean tmux cheat-sheet

By resources

sessions

list-sessions        ls         -- List sessions managed by server
new-session          new        -- Create a new session
@cleberjsantos
cleberjsantos / 1_google_cloud_storage_backup_tutorial.md
Created July 10, 2019 13:59 — forked from rnwolf/1_google_cloud_storage_backup_tutorial.md
Tutorial shows how to make backups to Google Cloud Storage.

Google Cloud Storage backup tutorial

Introduction

This tutorial shows how to make backups to Google Cloud Storage. The backups are:

  • automatic
  • stored off site
  • incremental
@cleberjsantos
cleberjsantos / remove_subtype.py
Last active June 8, 2019 23:57
Remove Subtypes do produto de busca facetada #plone #faceted
# -*- coding: utf-8 -*-
"""
This script list portlet assigments on a site.
Run the script using the following command line:
.. code-block:: console
$ bin/instance -O Plone run scripts/remove_subtype.py
@cleberjsantos
cleberjsantos / git-aliases.md
Created May 14, 2019 11:44 — forked from kelvinst/git-aliases.md
Git alias - seja rápido, seja breve!

Git alias - seja rápido, seja breve!

Git freak como sou, precisava compartilhar algo útil sobre ele, claro. E, já que não vejo muito por aí o pessoal usando, resolvi falar dos alias do git! É um recurso que eu uso muito, e nunca entendi porque muitas pessoas não são adeptas. 😕

Pelo nome você já deve perceber que os alias no git são atalhos. Atalhos pro quê? São atalhos para comandos do git e até comandos shell se você quiser. E é bem fácil cadastrar um alias:

$ git config --global alias.st status
@cleberjsantos
cleberjsantos / analise_broken.py
Last active June 8, 2019 23:53
Analise Broken
# -*- coding: utf-8 -*-
"""
This script list portlet assigments on a site.
Run the script using the following command line:
.. code-block:: console
$ bin/instance -O Plone run scripts/remove_broken.py