Git Product home page Git Product logo

Comments (5)

davidalger avatar davidalger commented on May 26, 2024

@ryantfowler If you still have interest in pursuing this, I wanted to followup and let you know I'd be interested in opening the door to allowing something like. What I'm thinking is it should be done something like the following:

  1. If the file ~/.warden/global-services.override.yml exists then it would be passed as an added compose file wherever docker/docker-compose.yml is used today.

  2. In doing this, the logic in up, down, start, stop, sign-certificate, and restart (all the places previously mentioned config file is referenced) would need to be unified to avoid further code duplication. This could be done by adding a function to say utils/global.sh and loading it similar to how utils/env.sh and others are in other places.

  3. Once the above is in place, the restart policy could be adjusted by placing the following overlay to adjust the restart policy as desired:

version: "3.5"
services:
  traefik:
    restart: never

  portainer:
    restart: never

  dnsmasq:
    restart: never

  tunnel:
    restart: never

Taking this approach has the advantage that it's flexible and also opens the door to other user-specific modifications to any of the global services deployed by Warden (including adding new ones to your own local setup).

Let me know. If this isn't something you wish to take on, I'll probably go ahead and close it out as I have not the use case to justify investing my own time in the endeavor at this point in time.

from warden.

ryantfowler avatar ryantfowler commented on May 26, 2024

@davidalger thanks for the follow up. Yes, I'd be interested in pursuing this. Please assign this to me.

from warden.

davidalger avatar davidalger commented on May 26, 2024

This morning a different and simpler concept came to me, inspired from a tweet by @talesh:
https://twitter.com/_Talesh/status/1222305123268825088

See what I just pushed up in 5073c5b. To use it you'd simple need to leverage one of the following lines in ~/.warden/.env:

WARDEN_RESTART_POLICY=no
WARDEN_SERVICE_DOMAIN=warden.test
TRAEFIK_LISTEN=127.0.0.1

Thoughts on this? The solution previously suggested may be overly complex here. Also do you think each service should warrant a different restart policy or is a single toggle sufficient for your use case?

from warden.

ryantfowler avatar ryantfowler commented on May 26, 2024

@davidalger Yea, I agree that is a simpler approach, and looks good to me.

Regarding a different reset policy for each service, or just one for all, I think a single toggle is good enough right now.

That said, I don't see any additional suggestions for this solution right now. You handled it 👍 Any general idea of when this could go out in a release (I can always patch my local with this until then, so I'm not being pushy).

from warden.

davidalger avatar davidalger commented on May 26, 2024

Going to publish this in Warden 0.2.1 release very shortly.

from warden.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.