Trigger "Tag creation" does not work when pulled mirror repo #2760
jmbz opened 1 month ago

Same as OD-2424. I'm only pulling the tags if that is the cause.

- type: PullRepository
    name: Sync tags
    remoteUrl: ...
    refs: refs/tags/*
    withLfs: false
    force: true
    condition: SUCCESSFUL
    optional: false
  • jmbz changed fields 1 month ago
    Name Previous Value Current Value
    Affected Versions
    14.1.4
    15.0.5
  • Robin Shen commented 1 month ago

    I created a test project to sync tags with a github project, and jobs can be triggered by pulled tags. Please create a test project here to see if it can be reproduced.

  • jmbz commented 1 month ago

    I pushed the project that I have the issue with: https://code.onedev.io/test-mirror2 As you can see the tags got pulled but that did not trigger the build job.

  • Robin Shen commented 1 month ago

    This happens as tag commit does not define any OneDev jobs. When pull tags, OneDev checks each tag commit to see if it contains OneDev build spec, and if yes, it continues to check each defined job to see if the trigger applies. Job defined in main branch does not apply for tags.

    This is designed to be so to make sure that behavior (OneDev job definitions) and data (commits the job runs against) are always from same commit.

  • Robin Shen changed state to 'Closed' 1 month ago
    Previous Value Current Value
    Open
    Closed
1/1
Type
Bug
Priority
Normal
Assignee
Affected Versions
15.0.5
Labels
No labels
Issue Votes (0)
Watchers (3)
Reference
OD-2760
Please wait...
Connection lost or session expired, reload to recover
Page is in error, reload to recover