fork of https://github.com/sourcegraph/zoekt
0

Configure Feed

Select the types of activity you want to include in your feed.

ci: only run sg PR creation after docker push (#597)

SG CI depends on the docker images being present. Now that our docker
images take longer to build with scip the race is easier to hit.

Test Plan: monitor main

+48 -56
+48 -2
.github/workflows/ci.yml
··· 78 78 79 79 # We build a shared docker image called "zoekt". This is not pushed, but is 80 80 # used for creating the indexserver and webserver images. 81 - # 82 - # While we run this job on main and PRs, the actual push is only done on the main branch. 83 81 docker: 84 82 if: github.ref == 'refs/heads/main' 85 83 runs-on: ubuntu-latest ··· 148 146 file: Dockerfile.indexserver 149 147 cache-from: sourcegraph/zoekt-indexserver:latest 150 148 push: true 149 + 150 + # We can only run this after a successful docker push otherwise the CI in sourcegraph will fail. 151 + sync-zoekt: 152 + if: github.ref == 'refs/heads/main' 153 + runs-on: ubuntu-latest 154 + needs: 155 + - "docker" 156 + steps: 157 + - uses: actions/checkout@v3 158 + with: 159 + repository: 'sourcegraph/sourcegraph' 160 + ref: 'main' 161 + - uses: actions/setup-go@v2 162 + with: { go-version: '1.19' } 163 + - run: go mod download 164 + - run: ./dev/zoekt/update 165 + - uses: peter-evans/create-pull-request@v3 166 + if: github.event_name == 'push' 167 + name: 'Create PR' 168 + id: pr 169 + with: 170 + token: ${{ secrets.GH_TOKEN }} 171 + title: 'zoekt: update to sourcegraph/zoekt@${{ github.sha }}' 172 + commit-message: 'zoekt: update to sourcegraph/zoekt@${{ github.sha }}' 173 + body: | 174 + This PR is autogenerated to update to sourcegraph/zoekt@${{ github.sha }} 175 + 176 + ## Test Plan 177 + 178 + Testing is done on the zoekt repo. All checks on this PR are sufficient. 179 + 180 + branch: 'zoekt/update' 181 + delete-branch: 'true' 182 + team-reviewers: 'search-team' 183 + base: 'main' 184 + 185 + - name: 'Check PR outputs' 186 + run: | 187 + echo "Pull Request Number - ${{ steps.pr.outputs.pull-request-number }}" 188 + echo "Pull Request URL - ${{ steps.pr.outputs.pull-request-url }}" 189 + - uses: peter-evans/enable-pull-request-automerge@v1 190 + name: Enable Pull Request Automerge 191 + if: steps.pr.outputs.pull-request-operation == 'created' 192 + with: 193 + token: ${{ secrets.GH_TOKEN }} 194 + pull-request-number: ${{ steps.pr.outputs.pull-request-number }} 195 + merge-method: squash 196 + repository: 'sourcegraph/sourcegraph'
-54
.github/workflows/pr.yml
··· 1 - name: sync zoekt 2 - on: 3 - push: 4 - branches: 5 - - main 6 - 7 - workflow_dispatch: 8 - branches: 9 - - main 10 - 11 - jobs: 12 - sync-zoekt: 13 - runs-on: ubuntu-latest 14 - steps: 15 - - uses: actions/checkout@v3 16 - with: 17 - repository: 'sourcegraph/sourcegraph' 18 - ref: 'main' 19 - - uses: actions/setup-go@v2 20 - with: { go-version: '1.19' } 21 - - run: go mod download 22 - - run: ./dev/zoekt/update 23 - - uses: peter-evans/create-pull-request@v3 24 - if: github.event_name == 'push' 25 - name: 'Create PR' 26 - id: pr 27 - with: 28 - token: ${{ secrets.GH_TOKEN }} 29 - title: 'zoekt: update to sourcegraph/zoekt@${{ github.sha }}' 30 - commit-message: 'zoekt: update to sourcegraph/zoekt@${{ github.sha }}' 31 - body: | 32 - This PR is autogenerated to update to sourcegraph/zoekt@${{ github.sha }} 33 - 34 - ## Test Plan 35 - 36 - Testing is done on the zoekt repo. All checks on this PR are sufficient. 37 - 38 - branch: 'zoekt/update' 39 - delete-branch: 'true' 40 - team-reviewers: 'search-team' 41 - base: 'main' 42 - 43 - - name: 'Check PR outputs' 44 - run: | 45 - echo "Pull Request Number - ${{ steps.pr.outputs.pull-request-number }}" 46 - echo "Pull Request URL - ${{ steps.pr.outputs.pull-request-url }}" 47 - - uses: peter-evans/enable-pull-request-automerge@v1 48 - name: Enable Pull Request Automerge 49 - if: steps.pr.outputs.pull-request-operation == 'created' 50 - with: 51 - token: ${{ secrets.GH_TOKEN }} 52 - pull-request-number: ${{ steps.pr.outputs.pull-request-number }} 53 - merge-method: squash 54 - repository: 'sourcegraph/sourcegraph'