transfered existing blog into a new hugo project
This commit is contained in:
@@ -0,0 +1 @@
|
|||||||
|
public/
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
[submodule "themes/hyde"]
|
||||||
|
path = themes/hyde
|
||||||
|
url = https://github.com/spf13/hyde.git
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
+++
|
||||||
|
date = '{{ .Date }}'
|
||||||
|
draft = true
|
||||||
|
title = '{{ replace .File.ContentBaseName "-" " " | title }}'
|
||||||
|
+++
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
title: "About"
|
||||||
|
date: 2019-04-28T20:45:47-06:00
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
Lead Developer, actually only developer, at a small delivery company.
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
---
|
||||||
|
title: Disqus for commments and a license
|
||||||
|
slug: adding-comments
|
||||||
|
date: 2017-12-10T13:28:26-07:00
|
||||||
|
tags:
|
||||||
|
- blog
|
||||||
|
- comments
|
||||||
|
- disqus
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
Update: I'm not using Disqus for comments anymore, see [Why you should quit disqus](https://victorzhou.com/blog/replacing-disqus/)
|
||||||
|
<!--more-->
|
||||||
|
I'm using [Disqus](https://disqus.com/home/) for comments. To set it up edit the conf.py in blog root, search for disqus. The shortname is put in COMMENT_SYSTEM_ID. While I was setting up comments I found a section for license. Check out [Creative Commons Chooser](https://creativecommons.org/choose/) to help select an appropriate license. I chose this one [non-commercial share alike](https://creativecommons.org/licenses/by-nc-sa/4.0/)
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
---
|
||||||
|
title: Blog script
|
||||||
|
slug: blog-script
|
||||||
|
date: 2017-06-01T20:26:53-06:00
|
||||||
|
.. tags: blog,documentation,web,nikola,script,bash
|
||||||
|
.. category:
|
||||||
|
.. link:
|
||||||
|
.. description:
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
I created a script for bash that automates creating a new post, rebuilding and deploying
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
~/.dotfile/blog.bash symlink in ~/bin
|
||||||
|
#!/bin/bash
|
||||||
|
#script to make blogging easier
|
||||||
|
|
||||||
|
#activate nikola
|
||||||
|
source ~/nikola/bin/activate
|
||||||
|
|
||||||
|
#create a new post
|
||||||
|
cd ~/myblog
|
||||||
|
nikola new_post -e
|
||||||
|
|
||||||
|
#build the new site
|
||||||
|
#nikola build
|
||||||
|
|
||||||
|
#deploy
|
||||||
|
#rsync -av --delete output/ ewpt3ch.com:/srv/http/ewpt3ch.com/blog/
|
||||||
|
|
||||||
|
#deactivate nikola
|
||||||
|
deactivate
|
||||||
|
|
||||||
|
simple and effective, pop open a terminal and away we go. in the future i may move the deployment into a different script so i can edit/revise before putting it up.
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
---
|
||||||
|
title: "Config Nginx"
|
||||||
|
date: 2019-04-30T21:56:25-06:00
|
||||||
|
draft: true
|
||||||
|
---
|
||||||
|
|
||||||
|
Nginx is fast, reloads fast, and most importantly easy to configure.
|
||||||
|
|
||||||
|
<!--more-->
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
---
|
||||||
|
title: creating my blog using Nikola
|
||||||
|
slug: creating-my-blog-using-nikola
|
||||||
|
date: 2017-05-30T21:18:45-06:00
|
||||||
|
tags:
|
||||||
|
- blog
|
||||||
|
- documentation
|
||||||
|
- web
|
||||||
|
- nikola
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
I switched to [Hugo](https://gohugo.io/getting-started/configuration/), see [this post](https://blog.ewpt3ch.dev/posts/mv-blog/)
|
||||||
|
<!--more-->
|
||||||
|
I decided to use [Nikola](https://getnikola.com/). It produces a static site from txt files in various formats, I chose [Markdown](https://daringfireball.net/projects/markdown/syntax) to be served directly by nginx on my server. Installation was pretty simple.
|
||||||
|
|
||||||
|
First make sure virtualenv is installed
|
||||||
|
|
||||||
|
$ sudo pip install virtualenv
|
||||||
|
$ test the install
|
||||||
|
$ virtualenv --version
|
||||||
|
|
||||||
|
Next we install Nikola
|
||||||
|
|
||||||
|
$ virtualenv nikola
|
||||||
|
$ source nikola/bin/activate
|
||||||
|
$ pip install --upgrade "Nikola[extras]"
|
||||||
|
Successfully installed Nikola
|
||||||
|
|
||||||
|
Now we have the tool installed, to exit the nikola environment use deactivate, everytime I blog use "source ~/nikola/bin/activate". Next we setup the site, without demo pages.
|
||||||
|
|
||||||
|
$ nikola init name_my_site
|
||||||
|
answer the questions in the wizard
|
||||||
|
edit path_to_blog/conf.py PAGES, POSTS, and COMPILERS to setup markdown
|
||||||
|
add a post
|
||||||
|
$ nikola new_post -e
|
||||||
|
rebuild the site
|
||||||
|
$ nikola build
|
||||||
|
|
||||||
|
Now we have a site that is ready for deployment to a server. Things that are coming later: scripts to enter and exit the virtualenv and deploy the posts automatically.
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
---
|
||||||
|
title: "Crostini containers"
|
||||||
|
slug: crostini-containers
|
||||||
|
date: 2019-05-16T20:37:16-06:00
|
||||||
|
tags:
|
||||||
|
- chromeos
|
||||||
|
- crostini
|
||||||
|
- containers
|
||||||
|
- customization
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
Chromeos is pretty awesome as a developement platform now with the integrated linux support. The project is called [Crostini](https://chromium.googlesource.com/chromiumos/docs/+/master/containers_and_vms.md#Crostini). To install you go to chromeos settings -> Linux and enable it. A locked down read-only VM is installed that uses LXD to run containers that have access to persistant storage. The default container is called penguin and runs a debian variation that has been modified by google. I prefer arch and since the containers run on LXD you can pull containers from [linux container image server](https://us.images.linuxcontainers.org/). If your preference is Fedora, Alpine(great for servers), Ubuntu they're all there. To use penguin just open the terminal app. Now let's go about getting an arch container up and running. First we need a crosh terminal, Ctrl-Alt-T. Once crosh is up we need to start the vm, it's called termina:
|
||||||
|
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
vmc start termina
|
||||||
|
|
||||||
|
Once we're in termina we can use lxc directly to see what the status of any available containers are and see what remotes and images are available.
|
||||||
|
```bash
|
||||||
|
lxc list
|
||||||
|
lxc remote list
|
||||||
|
lxc image list images:
|
||||||
|
```
|
||||||
|
|
||||||
|
Now the old way of starting and adding containers was using lxc. The new way is to use vmc or vsh from the crosh prompt.
|
||||||
|
```bash
|
||||||
|
crosh> vmc container termina arch
|
||||||
|
crosh> vsh termina arch
|
||||||
|
crosh> vmc container <vm> <container> [ <image server, full url> <image alias> ]
|
||||||
|
```
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
---
|
||||||
|
title: "Fish"
|
||||||
|
date: 2019-05-03T20:14:43-06:00
|
||||||
|
tags:
|
||||||
|
- linux
|
||||||
|
- shell
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
Let's use fish instead of bash. [fish shell](https://fishshell.com/) shell has many great features, dynamic auto suggestions, auto completion from man pages, a web based configuration tool, syntax highlighting, and ~~[Oh My Fish](https://github.com/oh-my-fish/oh-my-fish)~~ [Fisherman](https://github.com/jorgebucaran/fisher). Some great setup tips were on [Arch Linux Wiki](https://wiki.archlinux.org/index.php/Fish#Use_terminal_emulator_options). I chose launch it from my bashrc, add the following as the last line(if you need to get a bash shell run bash --norc)
|
||||||
|
<!--more-->
|
||||||
|
Add the following to .bashrc
|
||||||
|
|
||||||
|
exec fish
|
||||||
|
|
||||||
|
~~Installing Oh My Fish is this simple~~
|
||||||
|
|
||||||
|
|
||||||
|
Install fisherman
|
||||||
|
|
||||||
|
curl https://git.io/fisher --create-dirs -sLo ~/.config/fish/functions/fisher.fish
|
||||||
|
|
||||||
|
Then run fisher to update all the plugins in fishfile
|
||||||
|
|
||||||
|
fisher
|
||||||
|
|
||||||
|
Install plugins by
|
||||||
|
```bash
|
||||||
|
fisher add repo_name/package
|
||||||
|
fisher add oh-my-fish/theme-bobthefish
|
||||||
|
fisher add gitlab.com/repo_name/package
|
||||||
|
```
|
||||||
|
|
||||||
|
Here's a currated list of great plugins from the developer of fisher [awesome-fish](https://github.com/jorgebucaran/awesome-fish). I have installed:
|
||||||
|
```bash
|
||||||
|
oh-my-fish/theme-bobthefish
|
||||||
|
franciscolourenco/done sends a notification when a long running process completes
|
||||||
|
jethrokuan/fzf completions and bindings for the fuzzy finder app fzf
|
||||||
|
```
|
||||||
|
|
||||||
|
Tmux wouldn't correctly display some of the symbols in the themes. Solution is to start tmux with the -u option, explicitly set UTF-8. I also setup crostini to use powerline fonts so that spaceship theme would work. See [Crostini Fonts](https://www.reddit.com/r/Crostini/comments/9blkjv/powerline_fonts_in_the_crostini_terminal/)
|
||||||
@@ -0,0 +1,120 @@
|
|||||||
|
---
|
||||||
|
title: Setup and maintain gpg on yubikey
|
||||||
|
slug: gpg-on-yubikey
|
||||||
|
date: 2018-04-29T12:10:29-06:00
|
||||||
|
.. tags: gpg security openpgp howto linux encryption yubikey smartcard
|
||||||
|
.. category:
|
||||||
|
.. link:
|
||||||
|
.. description:
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
I have a [yubikey 4 nano](https://www.yubico.com/product/yubikey-4-series/#yubikey-4-nano) that I got specifically for the smartcard feature. This allows me to generate openpgp keys on the yubikey and the private key is usable yet unretrievable with software. This also allows me to store my master key on a USB stick that only gets plugged into a computer once a year when new keys need generating. For the initial setup I used this excellent guide from Eric Severance [PGP on a Yubikey](https://www.esev.com/blog/post/2015-01-pgp-ssh-key-on-yubikey-neo/). I'm going to outline the steps here that are required to create new signature and auth keys on the yubikey since they exprire every year.
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
#insert and mount the usb key with master key on it, then we move
|
||||||
|
#.gnupg to .gnupg.orig and symlink the usb gnupg to .gnupg
|
||||||
|
mv .gnupg .gnupg.orig
|
||||||
|
ln -s path/to/secure/gpg .gnupg
|
||||||
|
|
||||||
|
I'm following Eric's advice here and clearing my secret key and reimporting to make sure that everything is present.
|
||||||
|
|
||||||
|
# Refresh gnupg secret key
|
||||||
|
gpg --delete-secret-key keyID
|
||||||
|
gpg --import < /path/to/secure/gpg/keyID.pgp
|
||||||
|
|
||||||
|
gpg --edit-key keyID
|
||||||
|
|
||||||
|
# Create a new signing key
|
||||||
|
gpg> addcardkey
|
||||||
|
|
||||||
|
Signature key ....: [none]
|
||||||
|
Encryption key....: [none]
|
||||||
|
Authentication key: [none]
|
||||||
|
|
||||||
|
Please select the type of key to generate:
|
||||||
|
(1) Signature key
|
||||||
|
(2) Encryption key
|
||||||
|
(3) Authentication key
|
||||||
|
Your selection? 1
|
||||||
|
|
||||||
|
Please specify how long the key should be valid.
|
||||||
|
0 = key does not expire
|
||||||
|
= key expires in n days
|
||||||
|
w = key expires in n weeks
|
||||||
|
m = key expires in n months
|
||||||
|
y = key expires in n years
|
||||||
|
Key is valid for? (0) 1y
|
||||||
|
Key expires at
|
||||||
|
Is this correct? (y/N) y
|
||||||
|
Really create? (y/N) y
|
||||||
|
|
||||||
|
# repeat for the authentication key
|
||||||
|
|
||||||
|
gpg> addcardkey
|
||||||
|
|
||||||
|
Signature key ....: [none]
|
||||||
|
Encryption key....: [none]
|
||||||
|
Authentication key: [none]
|
||||||
|
|
||||||
|
Please select the type of key to generate:
|
||||||
|
(1) Signature key
|
||||||
|
(2) Encryption key
|
||||||
|
(3) Authentication key
|
||||||
|
Your selection? 3
|
||||||
|
|
||||||
|
Please specify how long the key should be valid.
|
||||||
|
0 = key does not expire
|
||||||
|
= key expires in n days
|
||||||
|
w = key expires in n weeks
|
||||||
|
m = key expires in n months
|
||||||
|
y = key expires in n years
|
||||||
|
Key is valid for? (0) 1y
|
||||||
|
Key expires at
|
||||||
|
Is this correct? (y/N) y
|
||||||
|
Really create? (y/N) y
|
||||||
|
|
||||||
|
gpg> save
|
||||||
|
|
||||||
|
Repeat the above for all yubikeys that you want associated with the master key. For encryption I generated the key in software and then added it to the yubikey, this way if I ever lose the key or use multiple keys I always have the encryption key somewhere. The procedure for generating and adding to the yubikey is as follows:
|
||||||
|
|
||||||
|
# Use toggle and key to select the private encryption key
|
||||||
|
gpg> edit-key keyID
|
||||||
|
gpg> toggle
|
||||||
|
gpg> key 1
|
||||||
|
gpg> keytocard
|
||||||
|
|
||||||
|
Please select where to store the key:
|
||||||
|
(2) Encryption key
|
||||||
|
Your selection? 2
|
||||||
|
gpg> save
|
||||||
|
|
||||||
|
The final step, and one which I keep forgetting hence this guide, is to export the public key, upload to the keyserver URL(specified on the yubikey), and then refresh everything.
|
||||||
|
|
||||||
|
gpg --edit-key keyID
|
||||||
|
gpg> showpref #this will show the keyserver
|
||||||
|
|
||||||
|
#backup the public key
|
||||||
|
gpg --armor --export keyID > keyID.asc
|
||||||
|
|
||||||
|
#upload
|
||||||
|
scp keyID user@server:path/to/file
|
||||||
|
|
||||||
|
Remove the master key and restore the original gpg directory. Next we fetch the new public keys and refresh everything so that gpg knows where the keys are and everything works.
|
||||||
|
|
||||||
|
gpg --card-edit
|
||||||
|
gpg/card> fetch
|
||||||
|
gpg/card> quit
|
||||||
|
gpg --card-status
|
||||||
|
|
||||||
|
That's it, everything should now work.
|
||||||
|
|
||||||
|
update:
|
||||||
|
|
||||||
|
Since I keep forgetting things, here's some tips for troubleshooting keys after creating new ones.
|
||||||
|
|
||||||
|
1) did you upload and move the public keys to the url location?
|
||||||
|
|
||||||
|
2) if gpg is showing old keys and you did 1, then delete the key to force and update
|
||||||
|
|
||||||
|
gpg --delete-keys keyID (make sure the offline usb is not plugged in)
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
---
|
||||||
|
title: "Moving my blog from Nikola to Hugo"
|
||||||
|
date: 2019-04-27T22:53:24-06:00
|
||||||
|
tags:
|
||||||
|
- blog
|
||||||
|
- nikola
|
||||||
|
- hugo
|
||||||
|
- go
|
||||||
|
- server
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
After some research I've determined that Nikola was too painful to use as a blogging engine. Entering a virt environment, mainting all that code and keeping it updated was tedious and it doesn't run on my espressobin. Hugo is my replacement of choice. Written in go it compiles into one binary and it runs on my espressobin. It works the same, I create the site on my remote machine, write posts in markdown, run hugo to pack it all up into a static site and send it to the server. Nice. Now to figure out a theme.....
|
||||||
|
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
The [terminal](https://github.com/panr/hugo-theme-terminal) theme fits what I'm blogging about best.
|
||||||
|
|
||||||
|
One issue that I had with hugo that I have since fixed was weird post summaries on the main page. To fix this use manual summary by adding
|
||||||
|
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
at the end of the portion wanted in the summary.
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
---
|
||||||
|
title: "ProtonMail Bridge Setup"
|
||||||
|
date: 2020-09-19T23:12:36-06:00
|
||||||
|
tags:
|
||||||
|
- mail
|
||||||
|
- protonmail
|
||||||
|
- howto
|
||||||
|
- guide
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
# Bridge Setup with seperate user
|
||||||
|
Protonmail Bridge is a neat little tool to get your protonmail emails onto your local machine. This offers several interesting possibilities for backup and using an alternative email client, ie mutt. Using it on linux is pretty painless, except for it's interaction with my password store. I use [pass](https://www.passwordstore.org/) with git and I have git setup to require signing for every commit. I also use a yubikey to store my gpg signing key and requires a pin for every signature. The protonmail bridge changes the information stored frequently and thus causes me an issue. I decided to solve it by creating a user, proton, on my system specifically to run the bridge with it's own password store just for protonmail. This solves my issue with entering my pin frequently and also limits exposure of my other passwords to the protonmail bridge program.
|
||||||
|
|
||||||
|
I used the -g option and added the new user to my group so that I would have access
|
||||||
|
|
||||||
|
`# sudo useradd -m -g myuser proton`
|
||||||
|
|
||||||
|
`# sudo su proton`
|
||||||
|
|
||||||
|
Create a gpg key, start a tmux session first to avoid gpg permission denied error
|
||||||
|
|
||||||
|
`# gpg --full-generate-key --expert`
|
||||||
|
|
||||||
|
select ecc and ecc, use comment section for details on it being for protonmail bridge user, no password
|
||||||
|
|
||||||
|
initialize the password store
|
||||||
|
|
||||||
|
`# pass init user@something.xyz`
|
||||||
|
|
||||||
|
Then setup the [protonmail bridge](../proton-mail-bridge)
|
||||||
|
|
||||||
|
Automating the startup of the bridge and getting mutt setup will be in a forthcoming post(s)
|
||||||
@@ -0,0 +1,151 @@
|
|||||||
|
---
|
||||||
|
title: "Proton Mail Bridge"
|
||||||
|
date: 2019-06-04T12:24:08-06:00
|
||||||
|
tags:
|
||||||
|
- mail
|
||||||
|
- mutt
|
||||||
|
- protonmail
|
||||||
|
- howton
|
||||||
|
- guide
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
# Bridge CLI summary
|
||||||
|
The available commands with description are listed bellow. The content of _CLI
|
||||||
|
configuration instructions_ should be added to Static website. The tab
|
||||||
|
completion and command history is available.
|
||||||
|
<!--more-->
|
||||||
|
## Command documentation
|
||||||
|
|
||||||
|
* all commands `help`
|
||||||
|
|
||||||
|
Commands:
|
||||||
|
change Change server or account settings (aliases: ch, switch)
|
||||||
|
check Check internet connection or new version.
|
||||||
|
clear Remove stored accounts and preferences. (alias: cl)
|
||||||
|
credits Print used resources.
|
||||||
|
delete Remove the account from keychain. Use index or account name as parameter. (aliases: del, rm, remove)
|
||||||
|
exit exit the program
|
||||||
|
help display help
|
||||||
|
info Print the configuration for account. Use index or account name as parameter. (alias: i)
|
||||||
|
list Print the list of accounts. (aliases: l, ls)
|
||||||
|
log-dir Print path to directory with logs. (aliases: log, logs)
|
||||||
|
login Login procedure to add or connect account. Optionally use index or account as parameter. (aliases: a, add, con, connect)
|
||||||
|
logout Disconnect the account. Use index or account name as parameter. (aliases: d, disconnect)
|
||||||
|
manual Print URL with instructions. (alias: man)
|
||||||
|
release-notes Print release notes. (aliases: notes, fixed-bugs, bugs, ver, version)
|
||||||
|
restart Restart the IMAP/SMTP server.
|
||||||
|
|
||||||
|
* subcommands for `check`
|
||||||
|
|
||||||
|
Check internet connection or new version.
|
||||||
|
|
||||||
|
Commands:
|
||||||
|
internet Check internet connection. (aliases: i, conn, connection)
|
||||||
|
updates Check for Bridge updates. (aliases: u, v, version)
|
||||||
|
|
||||||
|
|
||||||
|
* subcommands for `change`
|
||||||
|
|
||||||
|
Change server or account settings (aliases: ch, switch)
|
||||||
|
|
||||||
|
Commands:
|
||||||
|
mode Switch between combined addresses and split addresses mode for account. Use index or account name as parameter. (alias: m)
|
||||||
|
port Change port numbers of IMAP and SMTP servers. (alias: p)
|
||||||
|
|
||||||
|
|
||||||
|
* subcommands for `clear`
|
||||||
|
|
||||||
|
Remove stored accounts and preferences. (alias: cl)
|
||||||
|
|
||||||
|
Commands:
|
||||||
|
cache Remove stored preferences for accounts (aliases: c, prefs, preferences)
|
||||||
|
keychain Remove all accounts from keychain. (aliases: k, accounts)
|
||||||
|
|
||||||
|
|
||||||
|
## CLI configuration instructions
|
||||||
|
|
||||||
|
1. __Command Line Interface__: Start the Bridge command line interface from your terminal (to show all commands type `help` )
|
||||||
|
|
||||||
|
$ Desktop-Bridge --cli
|
||||||
|
Welcome to ProtonMail Bridge interactive shell
|
||||||
|
>>> list
|
||||||
|
No active accounts. Please add account to continue
|
||||||
|
|
||||||
|
1. __Add account__: Add your ProtonMail accounts(s) by `login` command and type in your `Username`, `Password`, optionally `Two factor code` (if enabled) and `Mailbox password` (if enabled)
|
||||||
|
|
||||||
|
>>> login
|
||||||
|
Username: benjerry
|
||||||
|
Password:
|
||||||
|
Authenticating ...
|
||||||
|
Adding account ...
|
||||||
|
Account benjerry successfully added
|
||||||
|
>>> list
|
||||||
|
# : account (status, address mode)
|
||||||
|
0 : benjerry (connected, combined)
|
||||||
|
|
||||||
|
1. __IMAP/SMTP Configuration__: Now your account is successfully connected to the Bridge. By default, you will be in combined addresses mode, which means that emails from all of your addresses will be sent and received together in the same mailbox. You type `info` to access the Bridge credentials for your mailbox. The parameter of `info` command is index or account name and tab-completion is supported.
|
||||||
|
|
||||||
|
|
||||||
|
>>> list
|
||||||
|
# : account (status, address mode)
|
||||||
|
0 : benjerry (connected, combined)
|
||||||
|
>>> info 0
|
||||||
|
Configuration for benjerry@protonmail.com
|
||||||
|
IMAP Settings
|
||||||
|
Address: 127.0.0.1
|
||||||
|
IMAP port: 1143
|
||||||
|
Username: benjerry@protonmail.com
|
||||||
|
Password: Xd4uRbsHYYxTElUMSsaVLg
|
||||||
|
|
||||||
|
SMTP Settings
|
||||||
|
Address: 127.0.0.1
|
||||||
|
IMAP port: 1025
|
||||||
|
Username: benjerry@protonmail.com
|
||||||
|
Password: Xd4uRbsHYYxTElUMSsaVLg
|
||||||
|
|
||||||
|
1. __Switching Address Mode__: If you would like to switch to split addresses mode, in which each address is added to the client separately, use command `change mode` followed by index or account name. In split addresses mode the `info` command prints the Bridge credentials for each of your addresses.
|
||||||
|
|
||||||
|
>>> change mode 0
|
||||||
|
Are you sure you want to change the mode for account benjerry to split mode? yes/No: yes
|
||||||
|
Address mode for account benjerry changed to split mode
|
||||||
|
>>> list
|
||||||
|
# : account (status, address mode)
|
||||||
|
0 : benjerry (connected, split)
|
||||||
|
>>> i 0
|
||||||
|
Configuration for benjerry@protonmail.com
|
||||||
|
IMAP Settings
|
||||||
|
Address: 127.0.0.1
|
||||||
|
IMAP port: 1143
|
||||||
|
Username: benjerry@protonmail.com
|
||||||
|
Password: Xd4uRbsHYYxTElUMSsaVLg
|
||||||
|
|
||||||
|
SMTP Settings
|
||||||
|
Address: 127.0.0.1
|
||||||
|
IMAP port: 1025
|
||||||
|
Username: benjerry@protonmail.com
|
||||||
|
Password: Xd4uRbsHYYxTElUMSsaVLg
|
||||||
|
|
||||||
|
|
||||||
|
Configuration for eyescream@protonmail.com
|
||||||
|
IMAP Settings
|
||||||
|
Address: 127.0.0.1
|
||||||
|
IMAP port: 1143
|
||||||
|
Username: eyescream@protonmail.com
|
||||||
|
Password: Xd4uRbsHYYxTElUMSsaVLg
|
||||||
|
|
||||||
|
SMTP Settings
|
||||||
|
Address: 127.0.0.1
|
||||||
|
IMAP port: 1025
|
||||||
|
Username: eyescream@protonmail.com
|
||||||
|
Password: Xd4uRbsHYYxTElUMSsaVLg
|
||||||
|
|
||||||
|
1. __Log out__: You can use `logout` command followed by index or name of account to disable sending / receiving of new emails. Your existing emails will still be stored in your client. If you are logged out, which can also happen if you change your password, you can use `login` command to connect your account again. To completely remove your account from Bridge use `delete` command.
|
||||||
|
|
||||||
|
>>> logout benjerry
|
||||||
|
Are you sure you want to logout account benjerry? yes/No: y
|
||||||
|
>>> delete benjerry
|
||||||
|
Are you sure you want to remove account benjerry? yes/No: y
|
||||||
|
Do you want to remove cache for this account? yes/No: y
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
---
|
||||||
|
title: rEFInd
|
||||||
|
slug: refind
|
||||||
|
date: 2017-06-02T20:56:04-06:00
|
||||||
|
.. tags: linux,uefi,boot,secureboot,bootloader
|
||||||
|
.. category:
|
||||||
|
.. link:
|
||||||
|
.. description:
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
Booting linux requires a [boot loader](https://wiki.archlinux.org/index.php/Category:Boot_loaders). I chose to use [rEFInd](http://www.rodsbooks.com/refind/index.html) vs GRUB or systemd boot. [Installing](https://wiki.archlinux.org/index.php/REFInd#Installation) is easy once the partitioning is setup. My partition scheme is a vfat esp partition of 512MB a ext2 boot partition 512MB and the rest of the disk for root on btrfs encrypted with dm-crypt and LUKS. This works for a bootable usb as well as internal drive. BTRFS was chosen for the subvolume feature. In the BTRFS root I create a /archroot and /home subvolume. On major system changes/upgrades I snapshot the /archroot subvolume to /archroot-date making a rollback simpler.
|
||||||
|
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
To configure kernels for rEFInd add a file called refind_linux.conf in the same folder(/boot) as the kernel(s). Add kernel command lines here.
|
||||||
|
|
||||||
|
#refind_linux.conf
|
||||||
|
"Boot with standard options" "root=UUID=123456 rw rootfstype=btrfs rootflags=subvol=arch acpi_backlight=video initrd=/intel-ucode.img initrd=initramfs-linux.img i915.enable_psr=0"
|
||||||
|
"Boot to single-user mode" "root=UUID=123456 single"
|
||||||
|
"Boot with minimal options" "root=UUID=123456"
|
||||||
|
|
||||||
|
additional options for LUKS would be added here.
|
||||||
|
change subvol=arch to subvol=arch-date to boot from snapshot
|
||||||
|
|
||||||
|
btrfs commands that I use frequently:
|
||||||
|
|
||||||
|
mount /dev/sdaX /mnt #mount the btrfs root(not /)
|
||||||
|
cd /mnt #change to the btrfs root
|
||||||
|
btrfs subvolume snapshot name-of-subvolume(arch) name-of-snapshot(arch-date)
|
||||||
|
|
||||||
|
update: Figured out how refind determines which kernel to boot automatically, it's the one with the most [recent date](https://sourceforge.net/p/refind/discussion/general/thread/87eec9bd/#6f53). Thinking about putting a hook into pacman or something to run touch on vmlinuz after kernel upadtes.
|
||||||
@@ -0,0 +1,95 @@
|
|||||||
|
---
|
||||||
|
title: "Sway Config"
|
||||||
|
date: 2021-05-06T19:23:15-06:00
|
||||||
|
tags:
|
||||||
|
- sway
|
||||||
|
- config
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
I had been using [dwm](https://dwm.suckless.org/) for a very long time. The keyboard focused interface and minimal resource usage were very appealing to me. When [swaywm](https://swaywm.org/) reached 1.0 release I gave it a try and was hooked. The only thing I really miss from dwm is the default window layout. Wayland uses less resources than xwindows for some reason and all the configuration is in the sway config or the configs for any apps, there is no Xresources and whatever other crazy amount of configs there were for xwindows and it's stack.
|
||||||
|
|
||||||
|
Progams that I'm using:
|
||||||
|
|
||||||
|
- [swaywm](https://swaywm.org/): compositor and window manager
|
||||||
|
- [waybar](https://github.com/Alexays/Waybar): bar and tray
|
||||||
|
- [mako](https://github.com/emersion/mako): notification daemon, replaces twmn from dwm setup
|
||||||
|
- [alacritty](https://github.com/alacritty/alacritty): terminal, switched from termite since it is no longer maintained.
|
||||||
|
- [wofi](https://hg.sr.ht/~scoopta/wofi): launcher, replaces dmenu from dwm setup
|
||||||
|
|
||||||
|
Sway allows for the config to be split between files using `include path/to/file/`. The include directive with parse out things like `$(hostname)` so that a machine specific config can be used as well as a default. I used this to create a seperate display config for my home workstation/laptop and my traveling laptop. One has 3 screens and the other typically only one hiDPI screen. This also works well with my new [dotfiles](https://blog.ewpt3ch.dev/posts/dotfiles) approach. Onto the configuration goodies.
|
||||||
|
Set some variables to use in the config
|
||||||
|
|
||||||
|
```config
|
||||||
|
### Variables
|
||||||
|
#
|
||||||
|
# Logo key. Use Mod1 for Alt.
|
||||||
|
set $mod Mod1
|
||||||
|
# Home row direction keys, like vim
|
||||||
|
set $left h
|
||||||
|
set $down j
|
||||||
|
set $up k
|
||||||
|
set $right l
|
||||||
|
# Your preferred terminal emulator
|
||||||
|
set $term alacritty
|
||||||
|
# Your preferred application launcher
|
||||||
|
set $menu wofi
|
||||||
|
# setup grim and slurp for screen shots
|
||||||
|
set $screenshot grim ~/Images/screenshots/scrn-$(date +"%Y%m%d-%H%M%S").png
|
||||||
|
set $screenclip slurp | grim -g - ~/Images/screenshots/scrn-$(date +"%Y%m%d-%H%M%S").png
|
||||||
|
set $mail termite --name=mail
|
||||||
|
set $mixer termite --name=mixer
|
||||||
|
set $volume /home/ewpt3ch/bin/volumeset
|
||||||
|
```
|
||||||
|
Setup the input devices:
|
||||||
|
|
||||||
|
```config
|
||||||
|
### Input configuration
|
||||||
|
# set capslock to be control
|
||||||
|
input * xkb_options ctrl:nocaps
|
||||||
|
# need to move this to machine level config
|
||||||
|
input "2:7:SynPS/2_Synaptics_TouchPad" {
|
||||||
|
accel_profile adaptive
|
||||||
|
pointer_accel .5
|
||||||
|
dwt enabled
|
||||||
|
tap enabled
|
||||||
|
tap_button_map lrm
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
Hide the cursor after time or when typing:
|
||||||
|
|
||||||
|
```config
|
||||||
|
# hide mouse cursor¬
|
||||||
|
seat seat0 hide_cursor 5000¬
|
||||||
|
seat seat0 hide_cursor when-typing enable
|
||||||
|
```
|
||||||
|
|
||||||
|
Some keybindings showing the use of previously set variables
|
||||||
|
|
||||||
|
```config
|
||||||
|
### Key bindings
|
||||||
|
#
|
||||||
|
# Notifications
|
||||||
|
bindsym Control+Space exec makoctl dismiss
|
||||||
|
bindsym Control+Shift+Space exec makoctl dismiss --all
|
||||||
|
|
||||||
|
# Screen capture
|
||||||
|
bindsym $mod+Print exec $screenshot
|
||||||
|
bindsym $mod+Shift+Print exec $screenclip
|
||||||
|
|
||||||
|
#media
|
||||||
|
bindsym XF86AudioMute exec $volume mute
|
||||||
|
bindsym XF86AudioRaiseVolume exec $volume up
|
||||||
|
bindsym XF86AudioLowerVolume exec $volume down
|
||||||
|
```
|
||||||
|
|
||||||
|
I got this python script to make [inactive windows transparent](https://github.com/swaywm/sway/blob/master/contrib/inactive-windows-transparency.py), we start it like
|
||||||
|
|
||||||
|
`exec --no-startup-id python ~/bin/inactive-windows-transparency.py`
|
||||||
|
|
||||||
|
Then the very last lines of the config bring in a system-wide default that gets updated by pacman and my machine-specific configurations
|
||||||
|
|
||||||
|
```config
|
||||||
|
include /etc/sway/config.d/*
|
||||||
|
include ~/.config/sway/$(hostname)/*
|
||||||
|
```
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
---
|
||||||
|
title: "Thinkpad E495 Arch Linux install"
|
||||||
|
date: 2020-02-17T22:32:16-07:00
|
||||||
|
tags:
|
||||||
|
- linux
|
||||||
|
- laptop
|
||||||
|
- install
|
||||||
|
- hardware
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
Gnupg to work with smart card needed to install pcsclite and ccid, enable/start pcscd.socket
|
||||||
|
For custom fpass to work needed to copy customized fzf,bash and pass to correct locations. need to create a package build for this
|
||||||
|
|
||||||
|
I got this decent piece of hardware a week earlier than expected, so it was a good thing that I had already ordered the hardware upgrades I wanted, those only arrived the day before the laptop. Since I had already installed [Arch Linux](https://www.archlinux.org/) on the 1TB NVME upgrade drive, the first thing I did was boot from that NVME enclosure to test my install on the actual hardware, I knew the install worked from booting on VirtualBox, but also to see if the e495 could boot from an external NVME enclosure. It did, unlike my [Yoga 2 Pro](https://en.wikipedia.org/wiki/Lenovo_Yoga_2_Pro). Once I had verified that the laptop booted my install I started with the upgrade process.
|
||||||
|
|
||||||
|
### Firmware and OEM Windows 10 Updates
|
||||||
|
|
||||||
|
During my research for this laptop I discovered that lenovo has not added it to the [Linux Vendor Firmware Service](https://fwupd.org/), kind of a bummer and able to be worked around. Also since this is a Ryzen laptop it is very imperative to be running the most [recent UEFI firmware](https://pcsupport.lenovo.com/us/en/products/laptops-and-netbooks/thinkpad-edge-laptops/thinkpad-e495-type-20ne/downloads/driver-list/). Another issue is that my studies at OU require use of software that only runs on Windows, so I wanted to test the software and get windows updated as well. To that end I spent a whole day running Windows update and then using the Lenovo update service for the firmware. Once all those updates were completed I proceeded to dismantle the laptop and replace/upgrade the NVME, 2.5" SSD, and RAM.
|
||||||
|
|
||||||
|
### Arch Linux Install
|
||||||
|
|
||||||
|
This install was pretty easy, didn't have to boot the new hardware from a live USB. Since the new NVME came before the laptop and I got a NVME external USB enclosure for the OEM NVME SSD to reside in, I just put the new NVME in there and did the install, mostly, from my yoga 2 pro which is already running Arch. First step was to decide on a partition scheme and filesystems. I decided to encrypt the whole system, to make things simple, the partitions scheme is:
|
||||||
|
|
||||||
|
```
|
||||||
|
Partition Mount Point filesystem options
|
||||||
|
nvme1 /boot/esp FAT32
|
||||||
|
nvme2 /boot ext4
|
||||||
|
nvme3 / btrfs dm-crypt with luks, compress=zstd subvolumes for /home / swap
|
||||||
|
sda1 /home/ewpt3ch/data btrfs dm-crypt with luks and keyfile, subvols for media and vms
|
||||||
|
```
|
||||||
|
|
||||||
|
[dm-crypt](https://wiki.archlinux.org/index.php/Dm-crypt/Encrypting_an_entire_system) is the most appropriate option for my attack surface, prevent access to my data if the system is lost or stolen. The second drive is also encypted and listed in crypttab with a keyfile stored in /etc/drive-keys, I figure if someone gets into the root partition it's already game over. I' still looking into using the TPMS somehow to automatically decrypt the drive or use a solokey or some other hardware token instead. If it's present decrypt, if not ask for a password. Currently it's just a password. Notice there is no swap partition. In order to keep things simple, we're using [swap files with systemd-swap](https://github.com/Nefelim4ag/systemd-swap). I thought BTRFS didn't support swap files, well that is not longer true according to [Arch Wiki](https://wiki.archlinux.org/index.php/Btrfs#Swap_file), [this pull request](https://github.com/Nefelim4ag/systemd-swap/pull/92), and [BTRFS FAQ](https://btrfs.wiki.kernel.org/index.php/FAQ#Does_btrfs_support_swap_files.3F).
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
---
|
||||||
|
title: "Thinkpad E495"
|
||||||
|
date: 2020-01-30T15:45:35-07:00
|
||||||
|
tags:
|
||||||
|
- linux
|
||||||
|
- laptop
|
||||||
|
- hardware
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
Decided to get a new laptop with the sale of my business and starting school. After a lot of research I decided on a [Lenovo Thinkpad E495](https://www.lenovo.com/us/en/laptops/thinkpad/thinkpad-e-series/E495/p/22TP2TEE495). I found the Ryzen 5(3500U) model at Best Buy with 8GB of ram and a 256GB SSD for $650 out the door. I decided to go with the Ryzen 5 over the 7 since the increase in performance didn't seem worth the extra $150. Also with the pending release of Renior and the new XPS 13 developer edition I decided to be as cheap as possible on this purchase and still get something I want and will probably be happy with for 2+ years. I decided on AMD CPU intead of Intel for 3 reasons: 1) support AMD because the Ryzen series seems to be pushing Intel to get better themselves 2) AMD seems to be less effected by the new hardware vulnerabilities coming out the last few years 3) better integrated graphics. I was looking at having 32GB RAM and at least a 500GB SSD, and this laptop series is upgradable. I will be getting a 2x16GB RAM kit and 1TB SSD from Amazon to put in for another $200 - $250. Still around $700 less than I'm thinking the XPS 9300 with 32GB will be and who knows how much or when the Renoir will be.
|
||||||
|
|
||||||
|
[I'll update when I get this hardware with a Arch Linux install guide and pictures.](../thinkpad-e495-arch)
|
||||||
|
|
||||||
|
In preperation for the arrival of the e495 I have ordered the upgraded hardrive, NVME and 2.5"sata, and 32GB ram kit. The NVME drive is here already so I've already installed the base system and setup a bootable systemd. For some reason Anubis, my yoga 2 pro, will not read the drive during boot so I resorted to using virtual box to boot the system. Following are links to the guides I have used so far, I will do another, more detailed post on the actual installation and steps. I have installed all the hardware upgrades, the laptop showed up a week earlier that expected. [Lenovo has a very detailed manual](https://download.lenovo.com/pccbbs/mobiles_pdf/e490_e495_e490s_ug_v2_en.pdf) with procedures for disassembling the laptop and replacing almost everything.
|
||||||
|
|
||||||
|
### Parts
|
||||||
|
- [1TB NVME SSD](https://smile.amazon.com/gp/product/B07K1J3C23/ref=ppx_yo_dt_b_asin_title_o00_s00?ie=UTF8&psc=1) and a
|
||||||
|
- [USB case for NVME SSD](https://smile.amazon.com/gp/product/B07MNFH1PX/ref=ppx_yo_dt_b_asin_title_o00_s00?ie=UTF8&psc=1).
|
||||||
|
- [Crucial 1TB 2.5" sata SSD](https://smile.amazon.com/gp/product/B077SF8KMG/ref=ppx_yo_dt_b_asin_title_o05_s01?ie=UTF8&psc=1)
|
||||||
|
- [Crucial 32GB Kit](https://smile.amazon.com/gp/product/B019FRCV9G/ref=ppx_yo_dt_b_asin_title_o05_s01?ie=UTF8&psc=1)
|
||||||
|
|
||||||
|
### Guides
|
||||||
|
- [dm-crypt](https://wiki.archlinux.org/index.php/Dm-crypt/Encrypting_an_entire_system#LUKS_on_a_partition)
|
||||||
|
- [rEFInd](https://wiki.archlinux.org/index.php/REFInd#Installing_the_rEFInd_Boot_Manager)
|
||||||
|
- [systemd-swap](https://github.com/Nefelim4ag/systemd-swap)
|
||||||
|
- [Arch Installation Guide](https://wiki.archlinux.org/index.php/Installation_guide)
|
||||||
|
- [BTRFS subvolumes](https://wiki.archlinux.org/index.php/Btrfs#Creating_a_subvolume)
|
||||||
|
- [BTRFS swap file](https://wiki.archlinux.org/index.php/Btrfs#Swap_file)
|
||||||
|
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
---
|
||||||
|
title: "tmux mouse scroll"
|
||||||
|
date: 2021-05-06T19:00:59-06:00
|
||||||
|
tags:
|
||||||
|
- tmux
|
||||||
|
- terminal
|
||||||
|
- configuration
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
The default setting for tmux interaction with the mouse is somewhat annoying. In a terminal window without tmux the mouse wheel will scroll the terminal line history, in tmux it scrolls through the command history. To change this behavior, and get and some other benefits, we have to add a config setting
|
||||||
|
|
||||||
|
```config
|
||||||
|
set -g mouse on
|
||||||
|
```
|
||||||
|
|
||||||
|
This enables the mouse wheel to scroll the output buffer instead of the command history. It also enables wrapped text selection by pane instead of whole terminal window and selecting text automatically copies it! This is pretty awesome, I've enabled it across all of my configs.
|
||||||
|
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
---
|
||||||
|
title: "VMWare and recent kernels"
|
||||||
|
date: 2019-06-05T20:29:10-07:00
|
||||||
|
tags:
|
||||||
|
- linux
|
||||||
|
- vmware
|
||||||
|
- kernel
|
||||||
|
---
|
||||||
|
|
||||||
|
VMware is still slow at updating their software to support newer linux kernel releases. I'm still using [vmware modules for linux](https://github.com/mkubecek/vmware-host-modules) on github. Download the branch corresponding to the version of vmware I'm currently using. I rewrote my module upgrade script to use these src files to build the modules.
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd path/to/src
|
||||||
|
make clean
|
||||||
|
make
|
||||||
|
sudo make install
|
||||||
|
sudo systemctl restart vmware
|
||||||
|
```
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
---
|
||||||
|
title: Vmware Player 14.0 on Arch Linux kernel 4.14
|
||||||
|
slug: vmware-player-140-on-arch-linux-kernel-414
|
||||||
|
date: 2018-01-14T21:39:10-07:00
|
||||||
|
tags:
|
||||||
|
- linux
|
||||||
|
- vmware
|
||||||
|
- kernel
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
VMware is slow, really slow, at updating their software to support newer linux kernel releases. I just found this [vmware modules for linux](https://github.com/mkubecek/vmware-host-modules) on github. It's a really cool repo with the patches already applied for the relevant vmware version to work with the latest kernel. I downloaded the zip file, created a tar ball of vmmon and copied that to /lib/vmware/modules/sources/ then ran my custom vmware-modupgrade script. Worked perfectly.
|
||||||
|
<!--more-->
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
baseURL = 'https://blog.ewpt3ch.dev/'
|
||||||
|
languageCode = 'en-us'
|
||||||
|
title = "Eric's Ramblings"
|
||||||
|
theme = 'hyde'
|
||||||
Submodule
+1
Submodule themes/hyde added at 2a3f431a85
Reference in New Issue
Block a user