Skip to content

Instantly share code, notes, and snippets.

View jakubgs's full-sized avatar
🔥
Notice me Senpai

Jakub jakubgs

🔥
Notice me Senpai
View GitHub Profile
@jakubgs
jakubgs / b32tob58.lua
Created February 6, 2019 14:34
Lua script for redirecting base32 domains to Infura IPFS base58 paths
--------------------------------------------------------------------------------
-- encoding configuration
--------------------------------------------------------------------------------
local base48Alphabet = "123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"
local base32Alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"
local base32PadMap = { "", "======", "====", "===", "=" }
--------------------------------------------------------------------------------
-- encoding function for base58

Conversation

23:19:24 sochan | hello, i have a question about using Nix as a way to prepare a build environment for a project                  │
23:20:11 sochan | right now we are using a default.nix using the standard mkDerivation to prepare an environement we envoke with  │
                | nix-shell to work in                                                                                            │
23:20:15 sochan | so we can build our project                                                                                     │
23:20:17 sochan | https://github.com/status-im/status-react/blob/develop/default.nix                                              │
23:20:38 sochan | but the thing is, that doesn't work for `nix build`, only for `nix-shell`                                       │
23:20:59 sochan | because we are not trying to build our software with nix, we are just trying to prepare a build enviornment for │
                | it                                                             

Description

The Nimbus cluster is configured via the infra-nimbus repo and mostly with the infra-role-beacon-node role.

Here are some thoughts from Sysadmin perspective.

Thoughts

Multiple Docker Images

{
"master-01.do-ams3.nimbus.test:9000@beacon-node-rlpx-testnet0-0-0": {
"Fork chosen": {
"lvl": "INF",
"ts": "2019-04-17 12:23:16+00:00",
"msg": "Fork chosen",
"tid": 1,
"newHeadBlockRoot": "2ED1CA08",
"newHeadEpoch": 1107,
"newHeadSlot": 17714
# This file is an example of the syntax required to call a Nix function
# and serves to test mkFilter.nix.
#
# nix-instantiate --strict --json --eval ./mkFilter_test.nix
# [
# {
# "expected": true,
# "path": "/home/pedro/src/github.com/status-im/status-react/android/1",
# "result": true
# },
WARN [07-18|18:58:56.557] Sanitizing cache to Go's GC limits provided=5604 updated=2491
INFO [07-18|18:58:56.557] Enabling metrics collection
INFO [07-18|18:58:56.560] Maximum peer count ETH=50 LES=100 total=150
INFO [07-18|18:58:56.560] Smartcard socket not found, disabling err="stat /run/pcscd/pcscd.comm: no such file or directory"
ERROR[07-18|18:58:56.561] Failed to enumerate USB devices hub=ledger vendor=11415 failcount=1 err="failed to initialize libusb: libusb: unknown error [code -99]"
ERROR[07-18|18:58:56.561] Failed to enumerate USB devices hub=trezor vendor=21324 failcount=1 err="failed to initialize libusb: libusb: unknown error [code -99]"
ERROR[07-18|18:58:56.561] Failed to enumerate USB devices hub=trezor vendor=4617 failcount=1 err="failed to initialize libusb: libusb: unknown error [code -99]"
ERROR[07-18|18:58:56.562] Failed to enumerate USB devices hub=ledger vendor=11415 failcount=2 err="failed to initialize libusb: libusb:
07-23 10:38:43.089 7259 7299 D ReactNativeJS: DEBUG [status-im.utils.handlers:32] - Handling re-frame event: :multiaccounts.login.ui/password-input-submitted
07-23 10:38:43.093 7259 7299 D ReactNativeJS: DEBUG [status-im.utils.keychain.core:191] - initializing realm encryption key...
07-23 10:38:43.094 7259 7299 D ReactNativeJS: DEBUG [status-im.utils.keychain.core:173] - PERF initializing realm encryption key... 1563892723093
07-23 10:38:43.096 7259 7299 D ReactNativeJS: DEBUG [status-im.data-store.core:29] - changing multiaccount to: 9b64770c9485a5188d238c305e53627a67c05d7d
07-23 10:38:43.099 7259 7299 D ReactNativeJS: DEBUG [status-im.data-store.realm.core:194] - closing account realm
07-23 10:38:43.127 7259 7300 D StatusModule: clearCookies
07-23 10:38:43.131 7259 7299 D ReactNativeJS: DEBUG [status-im.utils.handlers:32] - Handling re-frame event: :show-tab-bar
07-23 10:38:43.132 7259 7299 D ReactNativeJS: DEBUG [status-im.utils.handlers:32] - Handling re-frame event: :set
07-23 10:38:
### Stack
| Key | Value |
| --------------------------- | ------------------------------------------------------------------- |
| OS | 10.14.3 |
| Ruby | 2.5.3 |
| Bundler? | false |
| Git | git version 2.19.2 |
| Installation Source | /nix/store/m8z3qi5zbkm1mx38h14c6kf3dfnknyxf-ruby-2.5.3/bin/fastlane |
| Host | Mac OS X 10.14.3 (18D109) |
=== Kernel Version ===
Linux 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64
=== OS release ===
NAME="Ubuntu"
VERSION="16.04.6 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.6 LTS"
VERSION_ID="16.04"
package main
import (
"os"
"fmt"
"time"
"context"
"crypto/ecdsa"
"github.com/pkg/errors"
"github.com/google/uuid"