Information related to this gist is avaiable on my personal page.
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
-- init.lua | |
-- Automatically install lazy.nvim if not installed | |
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" | |
if not vim.loop.fs_stat(lazypath) then | |
vim.fn.system({ | |
"git", | |
"clone", | |
"--filter=blob:none", | |
"https://github.com/folke/lazy.nvim.git", |
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
TF_LOG=DEBUG terraform apply -var account_id=<account_id> -var api_key=<api_key> -var email="<user>@email.com" | |
2023-02-22T11:59:35.625-0300 [DEBUG] Adding temp file log sink: /tmp/terraform-log725224983 | |
2023-02-22T11:59:35.625-0300 [INFO] Terraform version: 1.0.10 | |
2023-02-22T11:59:35.625-0300 [INFO] Go runtime version: go1.16.4 | |
2023-02-22T11:59:35.625-0300 [INFO] CLI args: []string{"/home/<user>/.tfenv/versions/1.0.10/terraform", "apply", "-var", "account_id=<account_id>", "-var", "api_key=<api_key>", "-var", "email=<user>@email.com"} | |
2023-02-22T11:59:35.625-0300 [DEBUG] Attempting to open CLI config file: /home/<user>/.terraformrc | |
2023-02-22T11:59:35.625-0300 [DEBUG] File doesn't exist, but doesn't need to. Ignoring. | |
2023-02-22T11:59:35.625-0300 [DEBUG] ignoring non-existing provider search directory terraform.d/plugins | |
2023-02-22T11:59:35.625-0300 [DEBUG] ignoring non-existing provider search directory /home/<user>/.terraform.d/plugins | |
2023-02-22T11:59:35.625-0300 [DEBUG] ignoring non-existing provider |
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
FROM ubuntu | |
COPY script.sh /tmp/script.sh | |
RUN chmod +x /tmp/script.sh | |
CMD ["bash", "-c", "/tmp/script.sh"] |
Goal, assumption and requirements: It assumed a linux box running Ubuntu with bitcoind already running. It also assumed that golang binary is installed.
ubuntu@bitcoin:~$ go version
go version go1.17.4 linux/arm64
ubuntu@bitcoin:~$ bitcoind --version
Bitcoin Core version v22.0.0
Bitcoind must be configured to use zeromq, as it's the way lnd and bitcoin will talk to each other. Configuration file must have following lines:
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
- Install packages: | |
sudo apt install tor nginx | |
- Create a minimal config file for nginx on /etc/nginx/sites-enabled/tor: | |
server { | |
listen 127.0.0.1:80 default_server; | |
root /var/www/html; | |
# Add index.php to the list if you are using PHP |
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
import hashlib | |
import random | |
def generate_strings(length): | |
lower_chars = "abcdefghijklmnopqrstuvwxyz" | |
all_chars = lower_chars + lower_chars.upper() | |
while True: | |
yield ''.join(random.choice(all_chars) for i in range(length)) |
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 | |
VER=0.21.0 | |
ARCH="aarch64" | |
echo "Installing Bitcoind $VER" | |
setup(){ | |
sudo mkdir /data | |
UUID=$(sudo blkid -s UUID -o value /dev/xvdf1) | |
echo "UUID=$UUID /data ext4 defaults 0 0"| sudo tee -a /etc/fstab | |
sudo mount -a | |
sudo mkdir -p /data/{bitcoin,conf} |
I hereby claim:
- I am boris on github.
- I am borisquiroz (https://keybase.io/borisquiroz) on keybase.
- I have a public key whose fingerprint is F1B8 1974 430A B3EC 737F 0AC1 CE52 8506 9B8D 33E4
To claim this, I am signing this object:
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
package main | |
import "fmt" | |
func main() { | |
fmt.Println("hello world") | |
} |
NewerOlder