Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. PeerTube
  3. Peertube restarting over and over

Peertube restarting over and over

Scheduled Pinned Locked Moved Solved PeerTube
17 Posts 4 Posters 1.5k Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • nebulonN Offline
      nebulonN Offline
      nebulon
      Staff
      wrote on last edited by
      #8

      I think you went down the wrong path here. Unless the app is run in debug mode, it will always run /app/code/start.sh as the entry point. So any customization has to be done in /app/data/production.yaml for which we have to see if the kind of customization is even possible.

      To take a step back, maybe you can describe what you would like to have changed and then we can see what is the best avenue to achieve that and if it is even possible.

      jdaviescoatesJ 1 Reply Last reply
      0
      • nebulonN nebulon

        I think you went down the wrong path here. Unless the app is run in debug mode, it will always run /app/code/start.sh as the entry point. So any customization has to be done in /app/data/production.yaml for which we have to see if the kind of customization is even possible.

        To take a step back, maybe you can describe what you would like to have changed and then we can see what is the best avenue to achieve that and if it is even possible.

        jdaviescoatesJ Offline
        jdaviescoatesJ Offline
        jdaviescoates
        wrote on last edited by
        #9

        @nebulon sounds like @ChristopherMag just wants to disable outbound email:

        @christophermag said in Peertube restarting over and over:

        When I initially installed peertube I had outbound email configured.
        Due to a compliance issue I now have outbound email explicitly disabled so that no apps can send email external to the server.
        I don't know if I restarted peertube since making that change so this issue may have been one waiting to show up the first time it restarted after having outbound email disabled.

        I use Cloudron with Gandi & Hetzner

        1 Reply Last reply
        0
        • nebulonN Offline
          nebulonN Offline
          nebulon
          Staff
          wrote on last edited by
          #10

          Ah true got it. Well the package is currently built in a way where the start.sh will always overwrite the settings, since secrets may or may not be rotated on the server side or port numbers change after first installation (While is is not done currently, we still have all packages done in a way they can be changed)

          I don't really see an easy way to essentially "unconfigure" those without making the app error everytime it wants to send out a transactional email.

          Ideally there would be some suppported "never send out emails" configure option, but this may be quite the edge-case. Maybe you can try to set the transport to either null or sendmail and see if the app still works?

          ChristopherMagC 1 Reply Last reply
          0
          • nebulonN nebulon

            Ah true got it. Well the package is currently built in a way where the start.sh will always overwrite the settings, since secrets may or may not be rotated on the server side or port numbers change after first installation (While is is not done currently, we still have all packages done in a way they can be changed)

            I don't really see an easy way to essentially "unconfigure" those without making the app error everytime it wants to send out a transactional email.

            Ideally there would be some suppported "never send out emails" configure option, but this may be quite the edge-case. Maybe you can try to set the transport to either null or sendmail and see if the app still works?

            ChristopherMagC Offline
            ChristopherMagC Offline
            ChristopherMag
            wrote on last edited by
            #11

            @nebulon based on the current design I think the cleanest way to handle this is to change the behavior of Cloudron to be that when Outbound Email Relay configuration for a domain is set to disabled the smtp daemon referenced in the app containers via the environment variable CLOUDRON_MAIL_SMTP_SERVER continues to accept mail from applications and then deletes/routes all mail it receives to /dev/null (how to accomplish this would be dependent on the smtp daemon used).

            This would allow individual apps not to have to have configuration changes based on whether email is enabled or not.

            The other maybe more correct but difficult option is to change the state visible to the app container if Email Relay is set to disabled. This could be by no longer setting the various SMTP related environment variables so that the start.sh scripts can check for the presence of the variables before trying to use their values in configuration files.

            The app state change option requires that each app's start.sh has to account for this configuration possibility and then change the app's configuration based on that whereas the first option allows all apps configuration to remain consistent independent of whether Email Relay is disabled or not.

            6da06890-88f3-419d-b69c-f2ccefd00c81-image.png

            girishG 1 Reply Last reply
            0
            • ChristopherMagC ChristopherMag

              @nebulon based on the current design I think the cleanest way to handle this is to change the behavior of Cloudron to be that when Outbound Email Relay configuration for a domain is set to disabled the smtp daemon referenced in the app containers via the environment variable CLOUDRON_MAIL_SMTP_SERVER continues to accept mail from applications and then deletes/routes all mail it receives to /dev/null (how to accomplish this would be dependent on the smtp daemon used).

              This would allow individual apps not to have to have configuration changes based on whether email is enabled or not.

              The other maybe more correct but difficult option is to change the state visible to the app container if Email Relay is set to disabled. This could be by no longer setting the various SMTP related environment variables so that the start.sh scripts can check for the presence of the variables before trying to use their values in configuration files.

              The app state change option requires that each app's start.sh has to account for this configuration possibility and then change the app's configuration based on that whereas the first option allows all apps configuration to remain consistent independent of whether Email Relay is disabled or not.

              6da06890-88f3-419d-b69c-f2ccefd00c81-image.png

              girishG Offline
              girishG Offline
              girish
              Staff
              wrote on last edited by
              #12

              @christophermag Did I understand correctly that the issue is that peertube crashes if the SMTP server rejects the connection ? If so, I think I can make a patch for peertube upstream. Seems normal for SMTP servers to up/down, so an app should be able to cope with this anyways.

              ChristopherMagC 1 Reply Last reply
              0
              • girishG girish

                @christophermag Did I understand correctly that the issue is that peertube crashes if the SMTP server rejects the connection ? If so, I think I can make a patch for peertube upstream. Seems normal for SMTP servers to up/down, so an app should be able to cope with this anyways.

                ChristopherMagC Offline
                ChristopherMagC Offline
                ChristopherMag
                wrote on last edited by
                #13

                @girish Good thinking, yes that appears to be the behavior, if the smtp server rejects the connection the app refuses to start.

                girishG 3 Replies Last reply
                1
                • ChristopherMagC ChristopherMag

                  @girish Good thinking, yes that appears to be the behavior, if the smtp server rejects the connection the app refuses to start.

                  girishG Offline
                  girishG Offline
                  girish
                  Staff
                  wrote on last edited by
                  #14

                  @christophermag thanks, I can reproduce this easily.

                  1 Reply Last reply
                  0
                  • ChristopherMagC ChristopherMag

                    @girish Good thinking, yes that appears to be the behavior, if the smtp server rejects the connection the app refuses to start.

                    girishG Offline
                    girishG Offline
                    girish
                    Staff
                    wrote on last edited by
                    #15

                    @christophermag I have opened an issue upstream and make a PR as well - https://github.com/Chocobozzz/PeerTube/issues/3457 and https://github.com/Chocobozzz/PeerTube/pull/3458

                    1 Reply Last reply
                    1
                    • ChristopherMagC ChristopherMag

                      @girish Good thinking, yes that appears to be the behavior, if the smtp server rejects the connection the app refuses to start.

                      girishG Offline
                      girishG Offline
                      girish
                      Staff
                      wrote on last edited by
                      #16

                      @christophermag Change was merged, should be in next release of peertube.

                      ChristopherMagC 1 Reply Last reply
                      1
                      • girishG girish

                        @christophermag Change was merged, should be in next release of peertube.

                        ChristopherMagC Offline
                        ChristopherMagC Offline
                        ChristopherMag
                        wrote on last edited by
                        #17

                        @girish That is amazing, thank you!

                        1 Reply Last reply
                        1
                        Reply
                        • Reply as topic
                        Log in to reply
                        • Oldest to Newest
                        • Newest to Oldest
                        • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • Bookmarks
                          • Search