# Repeat execution and Some pipelines are lost

**URL:** <https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490>\
**Category:** Drone Support\
**Created:** [July 2, 2020, 8:54am UTC](https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490 "2020-07-02T08:54:54Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![yiduzui](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/yiduzui/32/5778_2.png) [@yiduzui](https://drone.discourse.group/u/yiduzui)\
**Post date:** [July 2, 2020, 8:54am UTC](https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490/1 "2020-07-02T08:54:54Z")

</div>

bug1: repeat execution. Update once with gitea edit will execute twice.

 ![image](https://canada1.discourse-cdn.com/flex003/uploads/testdrone/original/2X/9/95fdf74beea891422515cd58f7cb847da26c8e0e.png)

How to avoid multiple executions?

bug2: Multiple steps, only the first pipeline works, others are missing

```auto
# .drone.yml
kind: pipeline
type: kubernetes
name: CI测试
steps:
- name: 语法检查
  image: alpine
  commands:
  - echo dev
- name: 安全检查
  image: alpine
  commands:
  - echo dev
---
kind: pipeline
type: kubernetes
name: 镜像操作
steps:
- name: 代码review通知
  image: alpine
  commands:
  - echo "代码review通知"
steps:
- name: 构建镜像
  image: alpine
  commands:
  - echo "构建镜像"
steps:
- name: 镜像安全检查
  image: alpine
  commands:
  - echo "镜像安全检查"
---
kind: pipeline
type: kubernetes
name: 测试环境
steps:
- name: 自动化测试
  image: alpine
  commands:
  - echo dev
steps:
- name: 自动化测试2
  image: alpine
  commands:
  - echo dev

```

---

<div class="post-metadata">

**Author:** ![yiduzui](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/yiduzui/32/5778_2.png) [@yiduzui](https://drone.discourse.group/u/yiduzui)\
**Post date:** [July 2, 2020, 8:55am UTC](https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490/2 "2020-07-02T08:55:37Z")

</div>

add bug2 missing steps

 ![image](https://canada1.discourse-cdn.com/flex003/uploads/testdrone/original/2X/d/d7241d2d12d3664c9db9b720b775c808e4b44f4a.png)

missing steps 自动化测试

---

<div class="post-metadata">

**Author:** ![ashwilliams1](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/ashwilliams1/32/5549_2.png) [@ashwilliams1](https://drone.discourse.group/u/ashwilliams1)\
**Post date:** [July 2, 2020, 12:29pm UTC](https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490/3 "2020-07-02T12:29:52Z")

</div>

> [@"drone exec" does not support global pipeline variables](https://drone.discourse.group/t/drone-exec-does-not-support-global-pipeline-variables/7608/1):
>
> bug1: repeat execution. Update once with gitea edit will execute twice.

Drone executes a pipeline for each webhook it receives from Gitea. If Drone executes multiple builds it means Gitea sent multiple webhooks. Make sure only a single webhook is registered for your repository int he Gitea settings. If you continue to receive multiple webhooks from Gitea, please raise this issue with the Gitea community.

> [@"drone exec" does not support global pipeline variables](https://drone.discourse.group/t/drone-exec-does-not-support-global-pipeline-variables/7608/1):
>
> bug2: Multiple steps, only the first pipeline works, others are missing

This is not a bug, your yaml is malformed and has the `steps` block defined multiple times. Please correct your yaml as demonstrated in the below diff:

```diff
steps:
  - name: 代码review通知
    image: alpine
    commands:
    - echo "代码review通知"
- steps:
  - name: 构建镜像
    image: alpine
    commands:
    - echo "构建镜像"
- steps:
  - name: 镜像安全检查
    image: alpine
    commands:
    - echo "镜像安全检查"

```

---

<div class="post-metadata">

**Author:** ![yiduzui](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/yiduzui/32/5778_2.png) [@yiduzui](https://drone.discourse.group/u/yiduzui)\
**Post date:** [July 2, 2020, 1:50pm UTC](https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490/4 "2020-07-02T13:50:13Z")

</div>

Thank you.

 ![image](https://canada1.discourse-cdn.com/flex003/uploads/testdrone/original/2X/4/4f580986acc26167d848620a4de8cc2260c82631.png)

Maybe there are some problems with Gitea.This issue can be closed

---

<div class="post-metadata">

**Author:** ![nublaii](https://avatars.discourse-cdn.com/v4/letter/n/a9a28c/32.png) [@nublaii](https://drone.discourse.group/u/nublaii)\
**Post date:** [November 5, 2020, 2:32pm UTC](https://drone.discourse.group/t/repeat-execution-and-some-pipelines-are-lost/11490/5 "2020-11-05T14:32:37Z")

</div>

Apparently you need to [restart gitea after the first installation](https://github.com/go-gitea/gitea/issues/12124).

I leave this in case someone else is trying to figure out what’s happening.
