Skip to content

Latest commit

 

History

History
50 lines (31 loc) · 1.8 KB

install_wsl.md

File metadata and controls

50 lines (31 loc) · 1.8 KB

Run db-sync Docker Image on Windows Subsystem for Linux

In this guide you will set up WSL on your Windows, install Docker and run the db-sync docker image.

Prerequisites

  • PostGIS database
  • Windows 10 version 2004 and higher (Build 19041 and higher) or Windows 11 or Windows Server 2022

If you have older system version see manual install

Install WSL and Ubuntu

Open PowerShell or command prompt with administrative rights and the following command and restart your system:

wsl --install

If you have problems installing, see Microsoft WSL Installation docs for desktops or server 2022

On VM servers, you need to enable nested virtualisation on the parent Hyper-V host, see WSL FAQ.

You can now run your Ubuntu terminal from Windows Start menu and install Docker in WSL.

Install Docker

In your WSL Ubuntu terminal:

sudo apt install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
sudo apt update
sudo apt-cache policy docker-ce
sudo apt install docker-ce

Check the installation:

sudo docker run hello-world

In case of problems consult Docker on Ubuntu page.

Running db-sync Docker Image

After the steps above, you can run the docker image as described in Running with Docker.

If you run PostgreSQL server on your Windows host machine you can use $(hostname).local as the host name.