▲ 11 ▼ How do I interact with a git repo set up by docker compose in a persistent volume outside the container? (lemmy.world) submitted 7 months ago by early_riser@lemmy.world to c/linux4noobs@lemmy.world 12 comments fedilink hide all child comments
[+] early_riser@lemmy.world [S] 1 point 7 months ago* (3 children) [deleted] permalink fedilink source parent hideshow 3 child comments replies: [–] folekaule@lemmy.world 2 points 7 months ago (2 children) Ah ok. That explains a lot. I think what you are looking for is the git web server option for Otter wiki. How that probably works is that there is a git repo inside the container, and probably stored in /app-data. If you have that mount set up you may see what looks like a bare git repo in there. If you want to poke around inside the container, you can run a shell inside of it like this, assuming /bin/bash exists in the container: docker exec -it containername /bin/bash Anyway, you don't need to mess with that, because Otter wiki exposes a git server itself. All you have to do is clone the URL it gives you in the GUI, add your files, commit and push. So the most straightforward way is: Clone the repo to a local working copy: git clone https://otterwiki.example.com/repopath (the URL should show in the UI) Enter the directory: cd ./repopath Make your changes, add files, etc. Stage the changes git add . Commit the changes git commit -m "imported buncha files" Push them to the origin remote (Otter wiki): git push If you're not comfortable with the git command line, there are a bunch of TUI and GUI git clients you can use. It makes no difference which one. I usually just use the built-in vscode one for my hobby projects. permalink fedilink source parent hideshow 2 child comments replies: [+] early_riser@lemmy.world [S] 1 point 7 months ago (1 child) [deleted] permalink fedilink source parent hideshow 1 child comment replies: [–] folekaule@lemmy.world 1 point 7 months ago Happy to help. You may want to check out the section on Repository Management. The key here is to just treat it like any other git repo (like one on GitHub). In fact, you can set it up to pull/push from/to GitHub or another repo also, for off-site backup or collaboration outside your network. Make sure to clone the report to a local working copy first. From there, it should be pretty simple once you're familiar with the most common git commands (or use a UI). permalink fedilink source parent
[–] folekaule@lemmy.world 2 points 7 months ago (2 children) Ah ok. That explains a lot. I think what you are looking for is the git web server option for Otter wiki. How that probably works is that there is a git repo inside the container, and probably stored in /app-data. If you have that mount set up you may see what looks like a bare git repo in there. If you want to poke around inside the container, you can run a shell inside of it like this, assuming /bin/bash exists in the container: docker exec -it containername /bin/bash Anyway, you don't need to mess with that, because Otter wiki exposes a git server itself. All you have to do is clone the URL it gives you in the GUI, add your files, commit and push. So the most straightforward way is: Clone the repo to a local working copy: git clone https://otterwiki.example.com/repopath (the URL should show in the UI) Enter the directory: cd ./repopath Make your changes, add files, etc. Stage the changes git add . Commit the changes git commit -m "imported buncha files" Push them to the origin remote (Otter wiki): git push If you're not comfortable with the git command line, there are a bunch of TUI and GUI git clients you can use. It makes no difference which one. I usually just use the built-in vscode one for my hobby projects. permalink fedilink source parent hideshow 2 child comments replies: [+] early_riser@lemmy.world [S] 1 point 7 months ago (1 child) [deleted] permalink fedilink source parent hideshow 1 child comment replies: [–] folekaule@lemmy.world 1 point 7 months ago Happy to help. You may want to check out the section on Repository Management. The key here is to just treat it like any other git repo (like one on GitHub). In fact, you can set it up to pull/push from/to GitHub or another repo also, for off-site backup or collaboration outside your network. Make sure to clone the report to a local working copy first. From there, it should be pretty simple once you're familiar with the most common git commands (or use a UI). permalink fedilink source parent
[+] early_riser@lemmy.world [S] 1 point 7 months ago (1 child) [deleted] permalink fedilink source parent hideshow 1 child comment replies: [–] folekaule@lemmy.world 1 point 7 months ago Happy to help. You may want to check out the section on Repository Management. The key here is to just treat it like any other git repo (like one on GitHub). In fact, you can set it up to pull/push from/to GitHub or another repo also, for off-site backup or collaboration outside your network. Make sure to clone the report to a local working copy first. From there, it should be pretty simple once you're familiar with the most common git commands (or use a UI). permalink fedilink source parent
[–] folekaule@lemmy.world 1 point 7 months ago Happy to help. You may want to check out the section on Repository Management. The key here is to just treat it like any other git repo (like one on GitHub). In fact, you can set it up to pull/push from/to GitHub or another repo also, for off-site backup or collaboration outside your network. Make sure to clone the report to a local working copy first. From there, it should be pretty simple once you're familiar with the most common git commands (or use a UI). permalink fedilink source parent