Skip to content

Instantly share code, notes, and snippets.

View royki's full-sized avatar
😃
I may be slow to respond.

ROY royki

😃
I may be slow to respond.
View GitHub Profile
@royki
royki / create_eth_account.py
Created December 12, 2024 12:54
Create Eth Signer Address, private key with encrypted Keystore file with password
from eth_account import Account
import json
import subprocess
import os
from datetime import datetime
# Generate a random password using OpenSSL's rand -hex 32 command
def generate_random_password():
# Generate a random hex string of 32 bytes (64 characters)
result = subprocess.run(['openssl', 'rand', '-hex', '32'], capture_output=True, text=True)
@royki
royki / log.txt
Last active December 10, 2024 13:10
Collators logs
xcm-bob | 2024-12-10 13:08:30 [Relaychain] 🏆 Imported #105 (0xef98…5425 → 0xdf1f…826f)
xcm-bob | 2024-12-10 13:08:30 [Parachain] 🙌 Starting consensus session on top of parent 0x1a1982e5bdadfd79dea6e3816de2ef90e14068bcfe37359b4ae736d7e6c43cd2 (#0)
xcm-bob | 2024-12-10 13:08:30 [Parachain] panicked at /usr/local/cargo/registry/src/index.crates.io-6f17d22bba15001f/cumulus-pallet-parachain-system-0.17.1/src/lib.rs:1226:30:
xcm-bob | included head not present in relay storage proof
xcm-bob | 2024-12-10 13:08:30 [Parachain] 1 storage transactions are left open by the runtime. Those will be rolled back.
xcm-bob | 2024-12-10 13:08:30 [Parachain] 1 storage transactions are left open by the runtime. Those will be rolled back.
xcm-bob | 2024-12-10 13:08:30 [Parachain] ❗️ Inherent extrinsic returned unexpected error: Error at calling runtime api: Execution failed: Execution aborted due to trap: wasm trap: wasm `unreachable` instruction executed
xcm-bob | WASM backtrace:
xcm-bob
@royki
royki / cue_for_devops.md
Created May 19, 2024 23:45 — forked from ptMcGit/cue_for_devops.md
CUE for DevOps

CUE for DevOps

Overview

This is a tutorial that uses a toy infrastructure project to highlight some of CUE's features and show how it can be used to simplify and manage infrastructure. Go to Tutorial if you want to skip the introductory stuff.

What is CUE?

From cuelang.org:

@royki
royki / deploy.yaml
Created January 5, 2024 13:16 — forked from alonsoir/deploy.yaml
ansible script to gather VAULT_TOKEN from a VAULT server and run a process which need it. The idea is to maintain secrets in secure, deleting VAULT_TOKEN from file system and historic.
---
- name: Ejecutar Proceso con VAULT_TOKEN
hosts: localhost # Puedes ajustar los hosts según tu entorno
gather_facts: false # Desactivar recopilación de hechos
vars:
vault_address: "http://direccion-de-tu-vault:8200" # Ajusta la dirección de tu Vault Server
tasks:
- name: Establecer VAULT_TOKEN como variable de entorno

Keybase proof

I hereby claim:

  • I am royki on github.
  • I am royki (https://keybase.io/royki) on keybase.
  • I have a public key ASCQVvh550YJ-MixnyhzbZGNT4PJBsDl_4zj71yrvlsxIgo

To claim this, I am signing this object:

@royki
royki / alice.log
Created July 4, 2023 19:24
Relaychain Error
2023-07-04 19:16:36.788 TRACE tokio-runtime-worker gossip: Cleaned up 0 stale messages, 0 left (0 known) protocol=/cb78cf8b70f6db4099d9de03e2cdf98a56ef49fc04d22bd460a7b6bb598c4310/grandpa/1
2023-07-04 19:16:37.888 TRACE tokio-runtime-worker gossip: Cleaned up 0 stale messages, 0 left (0 known) protocol=/cb78cf8b70f6db4099d9de03e2cdf98a56ef49fc04d22bd460a7b6bb598c4310/grandpa/1
2023-07-04 19:16:38.079 INFO tokio-runtime-worker substrate: 💤 Idle (1 peers), best: #0 (0xcb78…4310), finalized #0 (0xcb78…4310), ⬇ 0 ⬆ 0
2023-07-04 19:16:38.403 DEBUG tokio-runtime-worker sync: Propagating transactions
2023-07-04 19:16:38.899 TRACE tokio-runtime-worker sub-libp2p: Ping time with PeerId("12D3KooWBzwDUvxn9X9Zz4E9SYgWoNYFwoMU6GRTJbD7E7tZYjpj"): 290.082µs
2023-07-04 19:16:38.924 TRACE tokio-runtime-worker sub-libp2p: Ping time with PeerId("12D3KooWBzwDUvxn9X9Zz4E9SYgWoNYFwoMU6GRTJbD7E7tZYjpj"): 211.812µs
2023-07-04 19:16:38.988 TRACE tokio-runtime-worker gossip: Cleaned up 0 stale messages, 0 left (0 know
@royki
royki / cloud-config.yml
Last active March 25, 2023 05:57
Packer template to build aws ami
package_update: true
package_upgrade: true
groups:
- docker
users:
- name: ubuntu
groups: docker
- name: telegraf
groups: docker
cloud_config_modules:
@royki
royki / blockscout-error.md
Created August 12, 2022 14:55
GenServer.call(Indexer.Fetcher.InternalTransaction, {:buffer, [19426479]}, 10000)
blockscout_1  | 2022-08-12T14:53:30.577 [error] Task #PID<0.3980.361> started from Indexer.Block.Realtime.Fetcher terminating
blockscout_1  | ** (stop) exited in: GenServer.call(Indexer.Fetcher.InternalTransaction, {:buffer, [19426479]}, 10000)
blockscout_1  |     ** (EXIT) no process: the process is not alive or there's no process currently associated with the given name, possibly because its application isn't started
blockscout_1  |     (elixir 1.13.1) lib/gen_server.ex:1019: GenServer.call/3
blockscout_1  |     (indexer 0.1.0) lib/indexer/block/realtime/fetcher.ex:385: Indexer.Block.Realtime.Fetcher.async_import_remaining_block_data/2
blockscout_1  |     (indexer 0.1.0) lib/indexer/block/realtime/fetcher.ex:224: Indexer.Block.Realtime.Fetcher.import/2
blockscout_1  |     (indexer 0.1.0) lib/indexer/block/fetcher.ex:167: Indexer.Block.Fetcher.fetch_and_import_range/2
blockscout_1  |     (indexer 0.1.0) lib/indexer/block/realtime/fetcher.ex:293: Indexer.Block.Realtime.Fetcher.do_fetch_and_import_blo
@royki
royki / Blockscout-error-log-1.md
Last active April 29, 2022 13:03
Could not insert all of chunk into Elixir.Explorer.Chain.InternalTransaction and ERROR 23503 (foreign_key_violation)
blockscout_1  | 
blockscout_1  | Options:
blockscout_1  | 
blockscout_1  | [conflict_target: [:block_hash, :block_index], on_conflict: #Ecto.Query<from i0 in Explorer.Chain.InternalTransaction, where: fragment("(EXCLUDED.transaction_hash, EXCLUDED.index, EXCLUDED.call_type, EXCLUDED.created_contract_address_hash, EXCLUDED.created_contract_code, EXCLUDED.error, EXCLUDED.from_address_hash, EXCLUDED.gas, EXCLUDED.gas_used, EXCLUDED.init, EXCLUDED.input, EXCLUDED.output, EXCLUDED.to_address_hash, EXCLUDED.trace_address, EXCLUDED.transaction_index, EXCLUDED.type, EXCLUDED.value) IS DISTINCT FROM (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", i0.transaction_hash, i0.index, i0.call_type, i0.created_contract_address_hash, i0.created_contract_code, i0.error, i0.from_address_hash, i0.gas, i0.gas_used, i0.init, i0.input, i0.output, i0.to_address_hash, i0.trace_address, i0.transaction_index, i0.type, i0.value), update: [set: [block_number: fragment("EXCLUDED.block_number"), call_type: fragment("EXCLUDED.c
@royki
royki / OpenVpn.md
Last active January 19, 2021 17:24
OpenVpn Client setup in windows
  1. In Windows - Edit registry key
  • Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters
  • Change following Value 0 to 1 IPEnableRouter