Skip to content

Instantly share code, notes, and snippets.

View redcapua's full-sized avatar

Volodymyr Samoylenko redcapua

View GitHub Profile
aasb = Unknown
action = Unknown
ad = Unknown
addh = Unknown
adsafe = Unknown
adtest = Ads test mode (when adtest=on, Google treats the query as a test so ad impressions aren’t counted)
adtest-useragent = Unknown
aec = Unknown
aep = Unknown
affdom = Unknown
@redcapua
redcapua / mongodb_backup.py
Created February 18, 2025 10:57 — forked from Lh4cKg/mongodb_backup.py
MongoDB Dump And Restore Database With Python PyMongo Driver
import bson
from pymongo import MongoClient
def dump(collections, conn, db_name, path):
"""
MongoDB Dump
@redcapua
redcapua / MF.md
Created May 9, 2022 05:38 — forked from xorik/MF.md
Польские инкубаторы

Moja Firma

https://mojafirma.org/

Шаги

  1. Вы заключаете контракт со своим клиентом (клиентами) или через фриланс биржи, используя юридические данные нашего бизнес-инкубатора;
  2. Полученные средства поступают на ваш фирменный суб-счет (валюта PLN, EUR, USD), которые вы потом себе выплачиваете как заработную плату в рамках договора с нами;
  3. Предоставив польским государственным органом подтверждение того, что вы тведете деятельность и проводите доход легально, вы получаете ВНЖ в Польше.
@redcapua
redcapua / index.html
Created November 21, 2021 14:33 — forked from chrisvfritz/index.html
Simplest possible HTML template
<!doctype html>
<html>
<head>
<title>This is the title of the webpage!</title>
</head>
<body>
<p>This is an example paragraph. Anything in the <strong>body</strong> tag will appear on the page, just like this <strong>p</strong> tag and its contents.</p>
</body>
</html>
@redcapua
redcapua / compact.js
Created May 13, 2020 15:37 — forked from BlakeGardner/compact.js
Compact all collections inside of a MongoDB database
// This script loops though the list of collection names in a MongoDB and runs the compact operation on them
// Simply paste this into the Mongo shell
use testDbName;
db.getCollectionNames().forEach(function (collectionName) {
print('Compacting: ' + collectionName);
db.runCommand({ compact: collectionName });
});

Angular Universal setup for firebase hosting

1) Install firebase-tools globally

npm i -g firebase-tools

2) Install @angular/platform-server

@redcapua
redcapua / .htaccess
Created August 7, 2019 18:28 — forked from boogah/.htaccess
Expire headers .htaccess code.
<IfModule mod_expires.c>
ExpiresActive on
# Perhaps better to whitelist expires rules? Perhaps.
ExpiresDefault "access plus 1 month"
# Data
ExpiresByType text/xml "access plus 0 seconds"
ExpiresByType application/xml "access plus 0 seconds"
ExpiresByType application/json "access plus 0 seconds"
@redcapua
redcapua / .gitignore_global
Created April 15, 2019 15:20 — forked from rainerkohlberger/.gitignore_global
Global git ignore Windows
# OS
.DS_Store*
ehthumbs.db
Icon?
Thumbs.db
Desktop.ini
# vvvv Backup
*~.xml
# Get Root
sudo su
# Download NMON archive
cd /tmp
wget http://sourceforge.net/projects/nmon/files/nmon16e_mpginc.tar.gz
# Untar archive
tar -xzvf nmon16e_mpginc.tar.gz
@redcapua
redcapua / gist:9afd22ab93c7a6bf240968a205b4bd1e
Created July 23, 2018 18:35 — forked from chrjoh/gist:3819587
Local setup of Jenkins on a mac
Jenkins
Download from jenkins and run the installer
Load and unload manually can be done with
load:sudo launchctl load /Library/LaunchDaemons/org.jenkins-ci.plist
unload: sudo launchctl unload /Library/LaunchDaemons/org.jenkins-ci.plist
heap-size
sudo defaults write /Library/Preferences/org.jenkins-ci heapSize 1024M