OK, I reckon I've cracked it. In the docker CLI SSH container (where I was trying to do mkdir) I did
docker cp ff333aef40fe:/rust.tgz /media/azd_shared_volume/
where ff333aef40fe was the ID of the container that I'd downloaded rust.tgz earlier (without the shared volume mounted).
Then I did "docker cp -L ff333aef40fe:/usr/bin/cc /media/azd_shared_volume/" to copy the linker that Rust needs.
Then in the almaLinux clone with the shared volume mounted I could see both files. So I proceeded to untar the tgz file but ran out of space.
So I deleted the old container (without the shared volume mounted) and this gave enough space - my system here is a bit short on disk space.
After that the tar -xzf worked and then I did the install.sh from the Rust install directory.
When I did "cargo run hello-world" (the name of my hello-world app), it failed as more than just 'cc' was required, so I went ahead and did the "yum install gcc" again.
After that (and deleting the 'cc' I copied above) the cargo run worked.
So, finally got there without having to download 390MB of rust install file, even if I did have to reinstall gcc, which was OK as a compromise.
Happy days!
cheers,
Peter
------------------------------
Thanks and regards,
Peter Bishop
------------------------------
Original Message:
Sent: Mon May 22, 2023 08:19 PM
From: Peter Bishop
Subject: How to sudo to avoid reinstalling Rust etc.
A bit more info...I added another admin user, and even when I supplied the password, sudo wouldn't let me mkdir.
So I cloned the almaLinux container and added a volume that mounted the AZD_SHARED_VOLUME at /shared in it, and suspect that I'll find it easiest just to reinstall Rust etc. into that volume for all to use as needed.
If anyone has a better idea on how to copy the data from the running almaLinux container into the shared volume in the cloned almaLinux container, I'd be keen to hear it.
Thanks again for reading and in advance for any ideas,
Peter
------------------------------
Thanks and regards,
Peter Bishop
Original Message:
Sent: Mon May 22, 2023 06:47 PM
From: Peter Bishop
Subject: How to sudo to avoid reinstalling Rust etc.
Hi,
I'd like to do sudo mkdir to make a copy of a container directory so I can make it persistent when I do a fresh start of the container (almaLinux).
I connect to the SSH CLI container with my public key via PuTTY successfully.
However, when I do sudo mkdir /backup, it asks me for my password.
I tried an empty string, and my RACF password, but neither worked. What password should I use? I'm just using local security, i.e. no LDAP.
I don't recall any password specification in the z/OSMF provisioning workflow apart from the entry of the public key, which works successfully as mentioned above. There doesn't seem to be any string with "password" in any of the JSON files used by the zCX address space. So it's a bit of a mystery at the moment.
Any ideas most welcome.
The aim is to avoid rerunning the Rust installation from scratch with a fresh volume created for almaLinux to use, but if I have to do that all over again, so be it. The steps there were pulling the almaLinux image, starting a container with it, installing gcc into that container, installing Rust into that container, and then doing the basic "hello world" check which worked. So if I can simply copy the Rust and gcc installation into a backup and use that, I'd much prefer to, but if I have to do it all again, I will. It seems there must be a way to avoid that, but I don't see it yet.
Thanks,
Peter
------------------------------
Thanks and regards,
Peter Bishop
------------------------------