PowerShell and Pode.Web on Ubuntu

Powershell is mainly used by system admins for Windows administration on the computers within their domain. With it, you can view and configure things like Active Directory, registry settings, start and stop services, etc. It is a very powerful tool, but it can also be dangerous in the wrong hands. It has execution policies that allow you to restrict access to only authorized users.

I wanted play around with Powershell. I am using an Ubuntu system, which will not include Windows Administration tasks. I will go through installation of Powershell on Ubuntu and setting up Pode.web.

Pode.web is a web template framework for use with the Pode PowerShell web server. It is simalar to Ruby's Sinatra or Python's Flask, but easier to use. You can build web sites completely with Powershell commands, and it doesn't require knowledge of html coding and style sheets. You can also build charts, forms, tables, general text, menus, tabs, and so on. It's quite impressive. Excellent documentation for it is provided at the following URLs:

https://badgerati.github.io/Pode.Web/0.8.3/

https://pode.readthedocs.io/en/latest/

Installation of Powershell

We will use a snap from the App Center in Ubuntu to install Powershell.

  1. Open the App Center.
  2. In Search for Apps, type Powershell.
  3. Click on Powershell app.
  4. Click Install.
  5. Open a Terminal window and type pwsh. You should see something like the following:
PowerShell 7.5.4
PS /home/user> 

Installation of Modules

We will install the following Powershell modules:

  • Pode
  • Pode.web
  • PSSqlite

Pode

From the Powershell command prompt, type the following to install the Pode module:

Install-Module -Name Pode

Pode.Web

From the Powershell command prompt, type the following to install the Pode.Web module:

Install-Module -Name Pode.Web

PSSqlite

From the Powershell command prompt, type the following to install the PSSqlite module:

Install-Module -Name PSSqlite

NOTE: We will use this module with the Pode.Web module in a future project.

Comments

Popular posts from this blog

Using Drupal and DITA OT to Create a PDF File

DokuWiki Docker Container

Favorite Docker Containers