Posts

Pyenv

pyenv pyenv allows you install multiple versions of python on the same computer. Prerequisites Mac:  Homebrew Windows:  Scoop Installation Mac: brew install pyenv Windows: Windows uses pyenv-win scoop install git scoop bucket add main scoop install main/pyenv

Poetry

Poetry  All about installing and using poetry for dependency management in python https://python-poetry.org/ https://realpython.com/dependency-management-python-poetry/ Prerequisite pipx must be installed on your system. Installation To install poetry open PowerShell if you are on Windows, or Terminal if you are on Mac, then type the following command. pipx install poetry Basic Usage Create a new poetry project: poetry new poetry-demo Add a package: poetry add package-name Initialising an existing project: cd project-directory poetry init Activate a poetry environment: poetry shell Deactivate an environment: exit or deactivate Install defined dependencies: poetry install

pipx

pipx pipx is used to install Python CLI applications globally while still isolating them in virtual environments. pipx will manage upgrades and uninstalls when used to install Poetry.  Requirements Mac: Homebrew Windows: Scoop Installation https://pipx.pypa.io/stable/installation/ Mac brew install pipx pipx ensurepath sudo pipx ensurepath --global Windows scoop install pipx pipx ensurepath

Homebrew

Homebrew Command line package manager for MacOS Installation Visit  https://brew.sh/ Follow the instructions

Scoop

 Scoop A command-line installer for Windows. Installation Open a PowerShell terminal Run these commands from C:\> Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression

My MacOS Dev Setup

Image
 MacOS Dev Setup These are the steps I use to setup a new MacOS machine, so that it has all the stuff that I use for software development. New Machine First Steps Start the new machine and create an account. Make sure you have your full name and the name of the account the way you would like. Add your Apple ID Install Xcode Machine Startup Sign into Apple ID, so that you have access to the store and iCloud. Settings General>About>Name (set your computer name) General>Software Update>Schedule Updates (so they run tonight) Trackpad>Point & Click>Tap to click Keyboard>Delay until repeat (one away from short) Accessibility>Zoom>Use scroll gesture with modifier keys to zoom Accessibility>Pointer Control>Trackpad Options>Use trackpad for dragging Accessibility>Pointer Control>Trackpad Options>Dragging style>Three Finger Drag Desktop & Dock>Click wallpaper to reveal desktop>Only in Stage Manager Internet Accounts&g

My Oh My Zsh Setup

Image
oh my zsh https://ohmyz.sh/ Oh my zsh is an open source project that allows you to customize your z shell. I use it for the following reasons: It makes my terminal look pretty It shows me what git branch I am on It shows me the status of my git repo It shows me the exit code for failed commands It shows my currently activated virtual environment It shows me my currently selected python version (via pyenv) It auto corrects my command line typos Installation Navigate to the installation page at  https://ohmyz.sh/#install , copy the curl command to perform the installation. A script will run that installs oh my zsh and modifies your ~/.zshrc file to load it. Configuration By default oh my zsh will set your theme for you and do some basic configuration. I prefer to use the powerlevel10k theme, which can be found here:  https://github.com/romkatv/powerlevel10k .  I followed the r

Hands at Work

  Hands at Work Recently my good friend Sherena asked "How much of your to-do list have you accomplished?", as I began responding I surprised myself in how much I've actually done. My response: :) I have a big todo list! I have done a fair amount of work on my home automation (installed lights, and switches). I did some more electrical repair, some of the outlets weren't working and required some troubleshooting. I've made several 3D cookie cutters for my neice. I setup a raspberry pi to work as an ad filter for the internet. I setup a blogger site for my old business domain. I began working on a blog series "AWS From Scratch" at http://www.baezaconsulting.com/. I began reading a really neat book series recommended by a friend of mine titled "he who kills monsters". I haven't powered up the laser recently, so maybe that will be next. The rest of my time is spent searching for jobs and interviewing. It's been a fun time, and there is a l

Pi-hole

Image
Pi-hole How I setup a Raspberry Pi 2 Model B as a dedicated DNS, DHCP, and Ad Blocking Server. What is Pi-hole? Pi-hole is a drop in replacement for your existing DNS server. It filters our know advertising websites so they don't show up in your browser (fewer ads).  Pi-hole is software that you install typically on a raspberry pi. The software sets up a dns server, an ad filter, a DHCP server, and a nice web based interface. My Setup I started with a Raspberry Pi 2 Model B Rev 1.1pi (32bit)  I put the pi in a case so it looked nicer under my TV cabinet, which is where it will live after I set it up. Image the microSD  To get the Raspberry Pi up and running I chose to start with a freshly imaged microSD, which will serve as the base operating system for the Raspberry Pi. Using the Raspberry Pi imager I Clicked on "CHOOSE OS" Then I selected "Raspberry Pi OS (other)" Then I chose "Raspberry Pi OS Lite (32-bit)" because my pi was only 32 bit and I chose

Idle Hands

Idle Hands So I recently found myself with a little more extra time than usual on my hands so I started compiling a list of things I would like to do. Blog Blog I recently revamped my two primary blogs, www.baeza.name and www.baezaconsulting.com. I decided to use blogger.com as my platform. It's easy to use, and I didn't have to set anything up. AWS From Scratch For the past week or so, I've been working on a series of blog posts walking through how to setup and use AWS from a beginners perspective called AWS From Scratch . I'm kinda making it up as I go. Ideally I would like to be able to touch on most every service available from AWS. For now I will just try to hit on the most critical components and see where that takes me. My Personal Blog Here we are. I re-created www.baeza.name and this is it. I'll try to post here to keep track of what I'm doing, what I plan on doing and what I've done so far. 3D Printing Cookie cutters! I have to get back to making s

AWS From Scratch 03 - Account Setup

Image
AWS From Scratch 03 - Account Setup Recap In AWS From Scratch 01 & 02, you created a new AWS account, Created an Organization to manage your account, and created an administrative user. You have followed the recommended best practices for creating accounts and users so far. Now you will continue following best practices by configuring your management account, and then add a sandbox account to work on project development. Management Account The management account should only be used to manage the organization and member accounts. It should not contain workloads or resources used by workloads (databases, files, etc.). Customizing the AWS access portal URL When you login using your non root administrative user, you use the Access Portal URL that was created when you enabled IAM Identity Center. The url contains numbers and letters and is not easy to remember (which is why you were asked to bookmark it). To change the URL into something more meaningful, login as the admin user and go t

AWS From Scratch 02 - Securing your Account

Image
 AWS From Scratch 02 - Securing your Account Now that you have signed up for AWS and provided your credit card information, you want to make sure that your account is properly setup and that you are using the best security so that your account is less likely to be hacked. The Root User When you first create your account you setup a password for the root user, which is the super user for the account. The root user has full access to everything in the account, including billing. It's best practice to not use the root user for daily tasks. In a large organization multiple users will be created each with a small portion of the permissions of root. So for example a developer might have certain privileges needed for just the type of development they are doing, while an accountant might only have access to the billing information. There are very few tasks that require you to login as the root user, for everything else you should create another user. Securing Root The first thing we should