For pull requests that modify the files Dockerfile or .devcontainer, we need to implement automatic triggering of the devcontainer_update workflow. This workflow ensures that the latest DevContainer is always updated for use by all other workflows, ensuring that subsequent builds incorporate the merged changes from the pull request.
Details:
Automatic Workflow Triggering: Whenever a pull request modifies the Dockerfile or .devcontainer files, the devcontainer_update workflow should be automatically invoked. This guarantees that subsequent builds utilize the latest changes from the merged pull request.
Scheduled Workflow Modification: The existing scheduled workflow triggers on each push to the main branch. However, it currently fails if triggered immediately after a pull request merge because it doesn't wait for the devcontainer_update workflow to complete. To address this, we need to modify the scheduled workflow to:
Wait for Completion: Ensure that the scheduled workflow does not start if the devcontainer_update workflow is running.
Trigger After Completion: Once the devcontainer_update workflow finishes executing, the scheduled workflow should automatically start to incorporate the updated DevContainer image.
Implementation Steps:
Implement logic to detect changes in the Dockerfile or .devcontainer files in pull requests.
Configure the triggering mechanism to automatically invoke the devcontainer_update workflow upon detection of such changes.
Modify the scheduled workflow to include checks for the devcontainer_update workflow's status before execution.
Define the workflow dependencies to ensure the scheduled workflow waits for the devcontainer_update workflow to complete before starting.
Contact Details
mustafa.bahaa
Description
Description
For pull requests that modify the files
Dockerfile
or.devcontainer
, we need to implement automatic triggering of thedevcontainer_update
workflow. This workflow ensures that the latest DevContainer is always updated for use by all other workflows, ensuring that subsequent builds incorporate the merged changes from the pull request.Details:
Automatic Workflow Triggering: Whenever a pull request modifies the
Dockerfile
or.devcontainer
files, thedevcontainer_update
workflow should be automatically invoked. This guarantees that subsequent builds utilize the latest changes from the merged pull request.Scheduled Workflow Modification: The existing scheduled workflow triggers on each push to the main branch. However, it currently fails if triggered immediately after a pull request merge because it doesn't wait for the
devcontainer_update
workflow to complete. To address this, we need to modify the scheduled workflow to:devcontainer_update
workflow is running.devcontainer_update
workflow finishes executing, the scheduled workflow should automatically start to incorporate the updated DevContainer image.Implementation Steps:
Dockerfile
or.devcontainer
files in pull requests.devcontainer_update
workflow upon detection of such changes.devcontainer_update
workflow's status before execution.devcontainer_update
workflow to complete before starting.