-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Separate system services in directories #38
base: master
Are you sure you want to change the base?
Conversation
good idea, thanks! please improve the update guide before we can merge this! |
@rugbymauri can be merged! |
885ae07
to
96114b9
Compare
Nice work @rugbymauri ! Only thing that's missing for me, is functionality to define default services that should be started on a project basis. @tuxes3 what's your opinion? |
What about introducing a Most project will use the current default. Therefore if the |
@tuxes3 so on a project basis?
We should automate that too. We could introduce a |
8af3de5
to
fed67a4
Compare
commands/system/update.sh
Outdated
_ddeCheckNetwork | ||
|
||
system:services:update dnsmasq | ||
system:services:enable dnsmasq |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rugbymauri the update command should only execute :update, not :enable. :enable should be handled by the up command.
Also we should get the list of services dynamically, in case a new service gets added
commands/system/up.sh
Outdated
for f in *; do | ||
if [ -f ${ROOT_DIR}/services/${f}/docker-compose.yml ]; then | ||
_logGreen "Starting service ${f}" | ||
cd ${ROOT_DIR}/services/${f} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be handled better
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be resolved by the commit 879864e
commands/system/stop.sh
Outdated
|
||
cd services | ||
|
||
for f in *; do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't we get the list of running services dynamically?
commands/system/update.sh
Outdated
system:services:update mailhog | ||
system:services:enable mailhog |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@s4mpl3d @rugbymauri probably mark as optional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xarem we should get a list of currently running services and only update those 👍
It's fundamentally a sound idea to structure services in such a way that the DDE system starts only those needed, rather than launching everything simultaneously. However, splitting them into multiple Docker-Compose files, each containing just one service, seems overly complex. A more effective approach would be to use Docker Compose's "Profile" feature (refer to Docker Compose Profiles). This feature allows assigning specific profiles to individual services, and only selected profiles are started. Consequently, a docker-compose up without specifying a service doesn't automatically start all containers. Additionally, I suggest creating a .dde.yml file in the respective project directories, which contains information about the required services. When executing dde up, this file would be read, and the relevant services would be initiated. This approach would also simplify documentation, as it eliminates the need to list individually which DDE services need to be started for optimal project development. In Pull Request #64, I've started implementing such a .dde.yml file. |
6309a2f
to
cca2b3c
Compare
️✅ There are no secrets present in this pull request anymore.If these secrets were true positive and are still valid, we highly recommend you to revoke them. 🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request. |
cca2b3c
to
971da1a
Compare
703bf24
to
8b68351
Compare
i refactored the PR. now, instead of creating/removing a file in the enjoy |
e776777
to
42b2739
Compare
Instead of listing all Services in the
docker-compose.yml
, each services as his owndocker-compose.yml
file.Services can be enabled and disabled, individually.
Allows to add new Services in the DDE-System.