Browse Source

new: [README.org] add WSL2 instruction

Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
pull/1/head
Valentin Lab 5 years ago
parent
commit
f139242e54
  1. 32
      README.org
  2. 2
      src/install.sh

32
README.org

@ -79,27 +79,39 @@ https://www.topbug.net/blog/2013/04/14/install-and-use-gnu-command-line-tools-in
*** Windows - docker for windows
*** Windows
There are many ways to use docker on windows.
There are different ways to run docker on windows, the preferred is on
WSL2 with a native docker daemon running in the WSL2 environment.
If you intend to use docker for windows, then you wont be able to use
our tool =compose= for the moment. However you can use the full blown
But this is still not out, so you might prefer to run "Docker For
Windows". In that latter case you won't be able to use our tool
=compose= for the moment. However you can use the full blown
=docker-compose= method.
**** Windows - docker for windows
**** Requirements
***** Requirements
- =bash= >= 4.3
- =docker= >= 17.06
- =docker-compose=
**** Deployment
***** Deployment
You'll need to get our charms if you want to use our same postgres
image.
This script will take care of what you need:
This script will take care of what you need if run from a bash in WSL:
#+BEGIN_SRC shell
curl -sS https://git.myceliandre.fr/Lokavaluto/dev-pack/raw/branch/dev/src/install.sh | bash
#+END_SRC
**** Windows - docker in WSL2
Just run this script in a bash session under WSL2:
#+BEGIN_SRC shell
curl -sS https://git.myceliandre.fr/Lokavaluto/dev-pack/raw/branch/dev/src/install.sh | bash
@ -110,10 +122,14 @@ curl -sS https://git.myceliandre.fr/Lokavaluto/dev-pack/raw/branch/dev/src/insta
*** using =compose=
This method only works if you are on linux, MacOSX, or Windows WSL2
with docker installed inside WSL2.
You need to create a =compose.yml= that suits your need. You can
create it wherever you want as long as either you launch =compose= in
a sub-directory or you specify the location of the =compose= file with
the =-f COMPOSEFILE= option. Here's a good start:
the =-f COMPOSEFILE= option. Here's a good start, execute these command
in a shell:
#+BEGIN_SRC shell
cat <<EOF > compose.yml

2
src/install.sh

@ -153,7 +153,7 @@ get_os() {
Linux*)
if [[ "$(< /proc/version)" =~ ^.*@(Microsoft|WSL).*$ ]]; then
e wsl
elif [[ "$(< /proc/version)" =~ ^.*-microsoft-*$ ]]; then
elif [[ "$(< /proc/version)" =~ ^.*-microsoft-.*$ ]]; then
e wsl2
else
e linux

Loading…
Cancel
Save