¿ªÔÆÌåÓý

Re: Have a working storage under VM/370


 

I haven't been following your Docker image creation process in
detail... but it sounds like you might be overcomplicating things
slightly.

Let's say you create a Dockerfile which places the VM370CE extracted
archive contents under /opt/VM370CE.V1.R1.2 in your image. When you
extract that, be sure to do a `chmod -w
/opt/VM370CE.V1.R1.2/disks/*.cckd` to remove all write access to the
base DASD images (this will force Hercules to create a snapshot/shadow
file on startup; the ro option in the hercules config file should also
do that, but no reason to have those cckd files writeable).

Then when you're ready to run your image, you just `docker run -v
/home/myuser/myshadowfiles:/opt/VM370CE.V1.R1.2/disks/shadows` and the
shadow files will be safely stored on your host system at
/home/myuser/myshadowfiles (obviously change to the path where you
want them) and mapped into the container at
/opt/VM370CE.V1.R1.2/disks/shadows. So they will be created the first
time your run Hercules, and preserved for multiple runs of the same
container, or be available if you run a new copy of the container.

-Matthew

On Sun, Apr 21, 2024 at 4:36?AM kwccoin via groups.io
<kwccoin@...> wrote:

I finally test the dockerfile arrangement (and coexist with non-dockerfile version):

The key is NOT to do docker run ... We should seperate 3 stages:

1. docker image stage (no volume, not expect any persistence.
2. docker container create stage where you can use internal volume or external mount
3. docker container start.

The use of run is ok but it will confuse one's mind. Instead, build a hercules image using step 1. Then map the external files you want under stage 2.

For docker run, you can use stage 3

For external run, as all files are external anyway, you can do either hercules -f ... or for mvs cd to mvs (or mvs-tk5) and run .mvs

---

However, one. must go back why I start with docker. The key is that I can run vm/370 without any hint how this is come about. Hence, another way is NOT to use external files. Then one can use volume or careful use of container. If one name the container and use container start, it will keep the information until you remove the container. It will run more a VM instead of as the one I used just somewhere and when you quit hercules inside the docker, everything is gone.

---

I am working on an example of both; I guess at least my past self will like to have the second option (dockerfile based) but also some hint how to be persistent at least in the same machine. (For publish one, not going there.)

Join [email protected] to automatically receive all group messages.