Skip to content

Instantly share code, notes, and snippets.

@marcelo1811
marcelo1811 / gist:53461fbe975e0e7321def048cecd022b
Created January 17, 2022 19:54 — forked from yuezhu/gist:47b15b4b8e944221861ccf7d7f5868f5
Generate self-signed certificate for HAProxy
# Generate a unique private key (KEY)
sudo openssl genrsa -out mydomain.key 2048
# Generating a Certificate Signing Request (CSR)
sudo openssl req -new -key mydomain.key -out mydomain.csr
# Creating a Self-Signed Certificate (CRT)
openssl x509 -req -days 365 -in mydomain.csr -signkey mydomain.key -out mydomain.crt
# Append KEY and CRT to mydomain.pem
const input = [
[1, 0, 0, 0, 1],
[1, 1, 0, 0, 0],
[0, 0, 0, 1, 0],
[0, 1, 0, 0, 1],
[0, 0, 1, 1, 1],
]
matrixSize = input.length - 1
@marcelo1811
marcelo1811 / build problems.md
Last active October 12, 2021 14:41
React Native

IOS

I had the same issue with the following library versions:

Xcode 6.3 Cocoapods 0.37.2 Finally I solved this issue by the following steps:

  • First step:
    Open Xcode Click Window (Menu Bar)
@marcelo1811
marcelo1811 / run-cmd.js
Last active October 11, 2021 13:17
script test to run cmd commands on node
const { exec } = require("child_process");
exec("pwd & ls -la", (error, stdout, stderr) => {
if (error) {
console.log(`error: ${error.message}`);
return;
}
if (stderr) {
console.log(`stderr: ${stderr}`);
return;