[–] 3 points 7 months ago

Not every term, certainly. But the first paragraph is a good at describing the primary purpose. And the last paragraph shows the breadth of services provided. I shared it thinking it could be the basis for further learning, or exploration of the project website to go and read more about it.

  • source
  • parent
  • context
  • [–] 2 points 7 months ago

    I like this answer: short and accurate enough.

    systemd handles a lot more than starting/stopping things, but that's the core of it. It is used by many (most?) up to date linux distros, but some stick to the older and simpler initd.

  • source
  • parent
  • context
  • [–] 2 points 7 months ago (2 children)

    The https://systemd.io main page has a pretty succinct answer to this:

    systemd is a suite of basic building blocks for a Linux system. It provides a system and service manager that runs as PID 1 and starts the rest of the system.

    systemd provides aggressive parallelization capabilities, uses socket and D-Bus activation for starting services, offers on-demand starting of daemons, keeps track of processes using Linux control groups, maintains mount and automount points, and implements an elaborate transactional dependency-based service control logic.

    Other parts include a logging daemon, utilities to control basic system configuration like the hostname, date, locale, maintain a list of logged-in users and running containers and virtual machines, system accounts, runtime directories and settings, and daemons to manage simple network configuration, network time synchronization, log forwarding, and name resolution.

  • source
  • [–] 4 points 7 months ago

    It manages your services at boot and allows you to start and restart them. If the HAL is the buffer between the kernel and the hardware, then systemd provides a layer between the kernel and the user/services. It's a super generic answer full of holes, but it's easy to start with

  • source
  • [–] 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).

  • source
  • parent
  • context
  • [–] 1 point 7 months ago*

    not to distribute server applications to end users, but to be used by developers who need a reproducible environment,

    What? No. It's extremely suited to be used as a server for client applications. I think you might want to learn a great deal more about docker before you come to that conclusion.

    Use bind mounts instead of named volumes for persistent data and it's a lot more predictable to use like you want.

  • source
  • parent
  • context
  • [–] 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:

    1. Clone the repo to a local working copy: git clone https://otterwiki.example.com/repopath (the URL should show in the UI)
    2. Enter the directory: cd ./repopath
    3. Make your changes, add files, etc.
    4. Stage the changes git add .
    5. Commit the changes git commit -m "imported buncha files"
    6. 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.

  • source
  • parent
  • context
  • [–] 3 points 7 months ago (4 children)

    I understand Docker can be confusing, especially if you're not a developer. Docker was developed to solve the problem of "it works on my computer" (but not yours), meaning it is meant to behave the same regardless of where it is installed. It does this by carrying all its dependencies with it. How well it succeeds in solving the problem is up for debate and I'm not here to debate the merits of Docker anyway.

    I would say two things: don't get discouraged:; it has a learning curve. And conversely: don't think Docker solves everything, either. Understanding how it works and what it can do is your best bet at using it successfully or even deciding that your use case is not right for it.

    I'm not familiar with Otter wiki (just heard about it today in this thread), but I will go by the online docs and see if I can help you get going. Going by the docker compose instructions, the example shows this compose file:

    services:
      otterwiki:
        image: redimp/otterwiki:2
        restart: unless-stopped
        ports:
          - 8080:80
        volumes:
          - ./app-data:/app-data
    

    The two last lines are key: the volumes section. The first and only entry maps a local directory ./app-data outside the container through a bind mount, to the path /app-data (note the leading slash) inside the container. It is mapped by default read-write, so the container can write to the directory. You can also read/write from the host side and put files you want in there.

    The files here are only stored in that one place (i.e., not copied), so if you want backups you need to take care of that separately.

    For your use-case, it may be enough to use the customization instructions for Otter wiki. Notice how their customized docker compose file has a second volume in it. In their example, you would put additional files into the ./custom directory on the host. It works the same as the app-data volume.

    That takes care of just running the application, but what if you wanted to customize it more? That is where you need to use the source and git. I am going to just use a fictional example app for this, because Otter wiki app may have some extra steps that can make it confusing. Basically what you want to do is clone the git repo of whatever you're building:

    git clone https://github/whatever
    

    Now you have the source. You can add files, make code changes, whatever. And once you're done with that you will use git as usual and commit the changes, push it to your branch, and maybe open a PR to the original repo. That's not important for Docker.

    The next thing you do is build the Docker image. Many people confuse Docker images and containers, but on short: the image is like the file system for the container, and the container is an instance of that file system + processes running on a Docker host. Many containers can run the same image on the same host and in fact that is how you horizontally scale an application.

    Once you have the image, you can just run it locally, or you can push it to a registry. Here is how you would do that:

    # Build the local image in the context . (current directory) and tag it as my-cool-app with tag latest
    # This uses the instructions in the Dockerfile to build the image. It can run commands, copy files, etc.
    docker build . -t my-cool-app:latest 
    # ...lots of messages...
    
    # Run the app - press control-C to stop it
    docker run --rm -it my-cool-app:latest 
    

    If you want to push it to Docker hub or another registry:

    # Tag the image with the repo name in front
    docker tag my-cool-app:latest registry.example.com/myuser/my-cool-app:latest 
    # Push the image to the registry
    docker push registry.example.com/myuser/my-cool-app:latest  
    

    One thing to keep in mind here is do not include any secrets with the image. If you do, anyone who can download the image can read them, because they get baked in with it.

    Let me know if you have any other questions and I'll be happy to answer.

  • source
  • parent
  • context
  • [–] 1 point 7 months ago* (last edited 7 months ago) (2 children)

    The stuff outside is likely exported from the container, but is likely just a link to what is inside, made to look transparent from the host but is not real.

    Containers create an overlay layer on top of the host. Some stuff on the host may still be linked directly.

    The abstract concept to understand here is that the thing you want to put in a container is likely to need outdated or different library (code) dependencies than the host machine. If you installed this software on the host, the conflicting dependencies are a nightmare and are likely to break stuff over time. So the container is the solution. It is as likely to be as small of an overlay image as possible and contains the dependencies that would otherwise conflict, and keeps them separate from the host.

    If you want to work with these, you must log into the container, and use the tools within. This will likely involve both the container and a Python venv layer, conda, or uv.

    It is also likely that docker is just an alias for podman on a Linux machine.

  • source
  • [–] 1 point 7 months ago* (7 children)

    I don't know the specifics of your app, but Docker containers aren't designed to be used for persistent data. They are designed to be immutable after they're built.

    Instead you would create a volume to keep files in and mount them where your application needs them. Typically like /data or /var/something. (Edit: otter wiki wants /app-data)

    You can use a bind mount to mount a local directory or a named volume which is kept in a set location by Docker. Generally bind mounts are easier to start with since you can browse the files directly on the host.

  • source
  • [–] 1 point 7 months ago

    The repo should just be some files, not actively "managed" from inside or outside the container. Interfering from outside might still cause some confusion.

    I assume the volume is created in /var/lib/docker/volumes. What's the error once you configured username and email?

    If you can't get it to work from outside, you can "log into" the running docker container with docker exec -ti CONTAINERID /bin/sh.

  • source
  • [–] [S] 1 point 7 months ago

    Just to close out this thread...

    The diagnostics didn't reveal anything problematic.

    I reinstalled fedora.

    Problem is gone. If it returns, I'll post a reply here.

  • source
  • [–] 2 points 7 months ago

    My next test would be trying to a live installation in order to see if it's hardware related or software.

    Boot into a live cd (I would use one that is the same distro as you already have) and do what you normally do. See if the machine locks up. If it doesn't then you've probably got some broken setting or program crashing your machine. If it does crash then some other hardware is causing the issue. You'd have to start taking out each piece of hardware out of the system to see if your crash is still there or not.

  • source
  • parent
  • context
  • [–] 1 point 7 months ago* (3 children)

    Then I would check the ram to make sure it's ok. Download memtest86+ load it on a thumbdrive and boot from that. Then run the memtests. It will tell you if your memory modules are fucked or not.

    The tests may take some time to run so go grab a beer while you wait.

  • source
  • parent
  • context
  • view more: ‹ prev next ›