• AbnormalHumanBeingOPMA
    link
    fedilink
    arrow-up
    1
    ·
    11 days ago

    So, the underlying issue was:

    For some reason, during the upgrade process, I managed to fuck up pict-rs working properly with lemmy. Note that I updated from scratch, not with docker or something similar.

    What happened was, that pict-rs simply wasn’t running and being started any more alongside lemmy

    My solution, which seems a bit hacky and improvised, admittedly, was to add a pict-rs service to systemd with the following config:

    [Unit]
    Description=pict-rs service
    After=network.target
    
    [Service]
    User=lemmy
    ExecStart=/usr/bin/pict-rs run -a 127.0.0.1:8080 filesystem -p /opt/lemmy/pictrs/files sled -p /opt/lemmy/pictrs/sled-repo
    #Environment=LEMMY_CONFIG_LOCATION=/opt/lemmy/lemmy-server/lemmy.hjson
    #Environment=PICTRS_ADDR=127.0.0.1:8080
    #Environment=RUST_LOG="info"
    Restart=on-failure
    WorkingDirectory=/opt/lemmy/pictrs
    
    # Hardening
    ProtectSystem=yes
    PrivateTmp=true
    MemoryDenyWriteExecute=true
    NoNewPrivileges=true
    
    [Install]
    WantedBy=multi-user.target
    
    

    So, basically a copy of the lemmy.service, with pict-rs being started. If soemone has better solutions, or can tell me why I may have broken some security or smth, feel free to speak up. If this ended up helping you, from the future, with a similar problem, I am happy to hear that!