This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
acl intermediate_fetching transaction_initiator certificate-fetching | |
http_access allow intermediate_fetching | |
# | |
# Recommended minimum configuration: | |
# | |
# Example rule allowing access from your local networks. | |
# Adapt to list your (internal) IP networks from where browsing | |
# should be allowed | |
acl localnet src 0.0.0.1-0.255.255.255 # RFC 1122 "this" network (LAN) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
let filterElasticsearchResponse = false; | |
let searchTerm; | |
$.ajaxSetup({ | |
beforeSend: function(xhr, settings) { | |
if( settings.url == window.epas.endpointUrl) { | |
filterElasticsearchResponse = true; | |
searchTerm = settings.headers['EP-Search-Term']; | |
} | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ruby '2.7.1' | |
gem 'rails', github: 'rails/rails' | |
gem 'tzinfo-data', '>= 1.2016.7' # Don't rely on OSX/Linux timezone data | |
# Action Text | |
gem 'actiontext', github: 'basecamp/actiontext', ref: 'okra' | |
gem 'okra', github: 'basecamp/okra' | |
# Drivers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# It assumes [asdf](https://github.com/asdf-vm/asdf) to be installed | |
# and asdf plugin for Ruby to be added | |
set -exuo pipefail | |
sudo apt install libreadline-dev | |
wget https://www.openssl.org/source/old/1.0.2/openssl-1.0.2u.tar.gz | |
tar -xzf openssl-1.0.2u.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For phpize | |
apt install php7.3-dev | |
# Install extensions | |
pecl install ev | |
pecl install event | |
# Create configurations | |
sudo echo 'extension=ev.so' > /etc/php/7.3/mods-available/ev.ini | |
sudo echo 'extension=event.so' > /etc/php/7.3/mods-available/event.ini |
I might make a big revision someday to review everything, fix anything that needs fixing, and explain the reason for each step. Maybe.
- Some computers won't work out of the box because of bugs left by the manufacturers.
Example
My laptop spams tty1 with the following errors when the network card starts being used:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export $(cat .env | grep -v ^# | grep -v ^alias | xargs) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# .ebextensions/cache.config | |
files: | |
"/opt/elasticbeanstalk/hooks/appdeploy/pre/02a_set_cache.sh": | |
mode: "000755" | |
owner: root | |
group: root | |
content: | | |
#!/bin/bash | |
set -xe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# One liner | |
wget --recursive --page-requisites --adjust-extension --span-hosts --convert-links --restrict-file-names=windows --domains yoursite.com --no-parent yoursite.com | |
# Explained | |
wget \ | |
--recursive \ # Download the whole site. | |
--page-requisites \ # Get all assets/elements (CSS/JS/images). | |
--adjust-extension \ # Save files with .html on the end. | |
--span-hosts \ # Include necessary assets from offsite as well. | |
--convert-links \ # Update links to still work in the static version. |
NewerOlder