Skip to content

Instantly share code, notes, and snippets.

@AlmogCohen
AlmogCohen / _README.md
Last active February 6, 2021 21:34 — forked from osdiab/_README.md
Deletes all your cached URLs in prerender

You can run this by doing the following:

  1. Log into https://prerender.io
  2. Open the developer console on the prerender site
  3. Copy the code in this gist and paste it into your console
  4. Hit enter!

Some notes:

  • This script takes a while, Prerender is not very performant! So if you have a lot of cached URLs, be patient.
var cleanUp = {
domains: [],
getDomains: async function() {
let results = null;
let page = 0
do {
const response = await fetch(`https://prerender.io/api/cached-pages?page=${page}&pageSize=1000`);
const json = await response.json();
@AlmogCohen
AlmogCohen / mindbody.html
Last active August 13, 2019 23:07
MindBody Healcode Widget De-Uglifier
<!-- The Mindbody healcode events widget is just broken and ugly by design.
I've been trying here to fix the design both by CSS and JS tricks.
Hope it will help someone. Hope Mindbody will make the effort to make their most visible widget
not as ugly as it is today. -->
<script src="https://widgets.healcode.com/javascripts/healcode.js" type="text/javascript"></script>
<healcode-widget data-type="enrollments" data-widget-partner="object" data-widget-id="55551774b27"
data-widget-version="0"></healcode-widget>
@AlmogCohen
AlmogCohen / gist:e9e0667e875f955e0d4783b7433ed604
Last active June 26, 2023 00:23
Dockerfile for Centos 6.10 with python 3.7 + pip + Pipenv
############################################################
# Dockerfile to build CentOS linux server with python3.7
# Can also use centos:6.9 as the origin dockerfile
############################################################
FROM centos:6.10
MAINTAINER Almog Cohen
# Install yum dependencies
RUN yum -y update && \
@AlmogCohen
AlmogCohen / README.md
Last active April 26, 2018 18:46
Installing Python 2.7 + pip + pipenv on Centos 6.9

Install yum dependencies

yum -y up date
yum groupinstall -y development && yum install -y bzip2-devel git hostname openssl openssl-devel sqlite-devel sudo tar  wget zlib-dev libffi libffi-devel

Install python2.7

cd /tmp && wget https://www.python.org/ftp/python/2.7.14/Python-2.7.14.tgz && tar xvfz Python-2.7.14.tgz && cd Python-2.7.14 && ./configure --prefix=/usr/local --enable-shared && make && make altinstall

Update libraries bindings

echo "/usr/local/lib" >> /etc/ld.so.conf

@AlmogCohen
AlmogCohen / gist:ed0a42884a8debfa43aa450f1662bdd8
Created March 13, 2018 17:28
Install and Use PIP on CentOS 6.9 with FIPS enabled
# Installing PIP via RPM
curl -O ftp://mirror.switch.ch/pool/4/mirror/centos/6.9/cloud/x86_64/openstack-juno/common/python-pip-1.3.1-4.el6.noarch.rpm
sudo yum install python-pip-1.3.1-4.el6.noarch.rpm
# Upgrade PIP
sudo pip install --upgrade pip -i https://pypi.org/simple/
# Install packages using simple PyPi
pip install <SOME_PACKAGE> -i https://pypi.org/simple/