1
0
Fork 0

Update container-README.md

pull/1753/head
H-Lo 5 years ago committed by GitHub
parent 0b1e26065b
commit e4bb17142c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -14,39 +14,43 @@ The container is a basic install of alpine linux, so the image
download is reasonably small download is reasonably small
On the container we have a few utilities and additionalsoftware that On the container we have a few utilities and additionalsoftware that
prezto has core support for prezto has core support for, and you can check it out in a snap by doing:
you can check it out in a snap by doing:
```bash
docker pull hlecuanda/prezto-dev:latest docker pull hlecuanda/prezto-dev:latest
```
once you have the image, create a container from it with: once you have the image, create a container from it with:
```bash
docker run -it --rm -h prezto hlecuanda/prezto-dev:latest docker run -it --rm -h prezto hlecuanda/prezto-dev:latest
```
that will set you on a prompt withing the container with a That will set you on a prompt within the container with a
vanilla install of prezto. vanilla install of prezto.
a development and testing run can be achieved by mounting the stuff A development and testing workflow can be achieved by mounting the stuff
you're working on to the image's filesystem: you're working on to the image's filesystem:
```bash
docker run -it --rm -h prezto \ docker run -it --rm -h prezto \
-v /local/path:/home/prezto \ -v /local/path:/home/prezto \
-v /local/path/zdotdir:/home/preztoa \ -v /local/path/zdotdir:/home/preztoa \
-v /local/module-dev-src:/home/prezto/.zprezto/modules/yourmodulea \ -v /local/module-dev-src:/home/prezto/.zprezto/modules/yourmodulea \
hlecuanda/prezto-dev:latest hlecuanda/prezto-dev:latest
```
the third volume mapping is particularly interesting. you can the third volume mapping is particularly interesting. you can
develop on your own machine and environnmen, and when spinning up the develop on your own machine and environnment, and when spinning up the
container, your actual source is already in-plase as if installed on a container, your actual source is already in-plase as if installed on a
vanilla prezto install. vanilla prezto instance
keep in mind that the container are ephemeral, unless you remove the keep in mind that the container are ephemeral, unless you remove the
--rm option which will create new containers each time you run the `--rm` option which will create new containers each time you run the
command, but the changes to the filesystemwill persist on a container command, but the changes to the filesystemwill persist on a container
file that you can later spin up again to re use. file that you can later spin up again to re-use.
I have found epehermeral containers to be most useful since you get an I have found epehermeral containers to be most useful since you get an
untainted, pristine environment for testing every time you spin up the untainted, pristine environment for testing every time you spin up the
container. container.
hope this turns out to be useful.

Loading…
Cancel
Save