Update README.md

This commit is contained in:
Lee 2024-09-21 04:48:44 +00:00
parent bb1ef32e29
commit 271400b9d5

@ -5,3 +5,24 @@ This is a helper for [Traefik](https://traefik.io/) on Kubernetes. It allows you
## Todo
- [ ] Use the Traefik api to list all services
## Windows Alias
Ensure you have ran `Set-ExecutionPolicy Unrestricted` in PowerShell as an administrator.
Create the directory `~/Documents/WindowsPowerShell` and create a file called `traefik.kubernetes.ps1` in that directory. Add the following code to the file.
```bash
function Traefik-Helper {
$argsAsString = $args -join ' '
$command = "projectlocation/traefik-helper-kubernetes/.venv/Scripts/python.exe projectlocation/traefik-helper-kubernetes/app.py $argsAsString"
Invoke-Expression $command
}
# Set the alias
Set-Alias -Name "traefik" -Value "Traefik-Helper"
```
This will allow you to run the `traefik` command in PowerShell.