Deploy the local RADIUS server container using Docker Desktop on Windows
In this topic, you will learn how to deploy the Portnox™ Cloud local RADIUS server container using Docker Desktop on a local Windows machine (physical or virtual).
Read the following important information before you begin:
-
We assume that the Windows machine is already installed, configured, updated, and connected to the local network. This guide includes only the installation and configuration of Docker Desktop and the Portnox Cloud local RADIUS server container.
-
You cannot place NAS devices behind a NAT because the local RADIUS server uses the source IP address of the connection, and with a NAT in place, that address would be the same for several NAS devices.
-
We recommend running Portnox Docker containers using Linux for performance reasons. Portnox Docker images are built for Linux so in Windows, they have to be run using virtualization. If you run Docker Windows in a virtual machine, you will need nested virtualization, which can affect performance.
Install Docker Desktop
In this section, you will follow Docker documentation to install Docker Desktop on the Windows machine.
Skip this section if Docker Desktop is already installed.
- Optional:
If you want to run Docker Desktop in a virtual machine, enable nested virtualization in your hypervisor on the host
machine.
This step depends on the hypervisor that you are using. Below are some examples for popular hypervisors. Consult the documentation of your hypervisor for more information.
-
Hyper-V: Execute the following command in PowerShell with administrative privileges:
Set-VMProcessor -VMName "vm_name" -ExposeVirtualizationExtensions $true
where vm_name is the name of your virtual machine.
-
VirtualBox: Go to Enable Nested VT-x/AMD-V option.
and turn on the -
VMware Workstation: Go to Virtualize Intel VT-x/EPT or AMD-V/RVI option.
and turn on the
-
-
Enable the Windows Subsystem for Linux (WSL) and install Ubuntu:
Note: For detailed instructions on how to enable WSL and install Ubuntu, see official Microsoft documentation.Note: You can run Docker Desktop with WSL or Hyper-V. WSL is recommended for performance reasons. If you need to run Docker Desktop with Hyper-V instead, refer to the official Docker and Microsoft documentation.
Result: WSL with Ubuntu is ready and you can proceed with Docker installation.
-
Install Docker Desktop:
Note: For detailed instructions on how to install Docker Desktop, see official Docker Desktop documentation.
-
Run Docker Desktop from the Start menu or the desktop icon.
- Optional:
Test Docker in the Windows command line:
Run the Portnox Cloud local RADIUS container
In this section, you will deploy the local RADIUS server Docker container locally to the Windows machine.
-
Open a command prompt with administrative privileges and run the portnox/portnox-radius
Docker container.
docker run -d -p 1812:1812/udp -p 1813:1813/udp ^ --name portnox-radius --restart=always ^ -v portnox-radius-data:/data ^ -e RADIUS_GATEWAY_PROFILE=copied_RADIUS_GATEWAY_PROFILE ^ -e RADIUS_GATEWAY_ORG_ID=copied_RADIUS_GATEWAY_ORG_ID ^ -e RADIUS_GATEWAY_TOKEN=copied_RADIUS_GATEWAY_TOKEN ^ portnox/portnox-radius:latest
where copied_RADIUS_GATEWAY_PROFILE, copied_RADIUS_GATEWAY_ORG_ID, and copied_RADIUS_GATEWAY_TOKEN are the values of the three environment variables that you saved earlier. You can also copy them now directly from Portnox Cloud: .
Note: The -v option creates and mounts a Docker volume that preserves the local RADIUS server data in case the container stops running, for example, if the machine is restarted or crashes. Without this option, local RADIUS cached data would be lost if the container stops running. To learn more about Docker volumes and an alternative, bind mounts, see Docker documentation. - Optional:
View the logs for the portnox/portnox-radius Docker container.
docker logs portnox-radius -f
- Optional:
Check if your NAS is configured correctly and if the RADIUS packets are reaching your Docker container.
docker exec -it portnox-radius sh / #apk add tcpdump / #tcpdump -i eth0 -v port 1812
Result: Your local RADIUS server is active.
You can check its status in Portnox Cloud, in the
section.