Docker? hur kommer jag åt filerna?

Permalänk

Docker? hur kommer jag åt filerna?

Jag provade nyligen att installera docker i DSM 6.1 (Synologys operativsystem för NAS:ar)
Jag provade att installera Tomcat/Apache genom menyn och får upp tomcat sidan om jag använder 192.168.1.77:32769
Jag lyckade även hitta på själva indexsidan via ssh på:

./volume2/@docker/btrfs/subvolumes/df590fc2e8ee0dcd42336a7c5762a1810199c0bb7b9bab60580b88ada218b22e/usr/local/tomcat/webapps/ROOT/index.jsp

Men jag kom inte åt indexfilen via SFTP av någon anledning.
Jag fick sedan tips om att använda kommandot docker exec -ti tomcat1 /bin/bash vilket funkade men jag kan inte använda nano eller göra speciellt mycket mer därifrån.

Hur är det tänkt att man ska göra om man vill ändra eller byta ut sidan som körs?

Permalänk
Medlem

Är inte helt haj på docker men jag gissar att man kan montera mappar för användning i sina containrar.

Citat:

You should either use the COPY instruction in your Dockerfile to copy the files into the htdocs location in your container while building your Apache image Or another best way to do is to use Docker Volume to map the content of htdocs from your host machine to the htdocs directory of the container.

You can refer the docs of httpd official Dockerfile here https://hub.docker.com/_/httpd/52

Googlade lite snabbt fram:
http://www.mastertheintegration.com/virtualization/docker/acc...
https://forums.docker.com/t/uploading-web-source-files-to-apa...

Visa signatur

PSU: Seasonic FOCUS Plus 750W Gold | MOBO: ASUS ROG STRIX X570-E | CPU: AMD Ryzen 9 5900X w/ NZXT Kraken x72 | GPU: EVGA GeForce GTX 1070 Ti FTW ULTRA SILENT GAMING | RAM:Corsair Vengeance DDR4 3200MHz CL16 (2X32GB) | SSD(s): 2X NVMe M.2 Samsung 970 EVO PLUS 1TB
AKA:FakeNinja