Skip to content

Commit d7b647e

Browse files
authored
prod: skip final pull (#5448)
* prod: skip final pull * fix: get tests to work * Apply suggestion from @beckermr
1 parent e5bd9bf commit d7b647e

File tree

12 files changed

+55
-15
lines changed

12 files changed

+55
-15
lines changed

.github/workflows/bot-bot.yml

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ jobs:
5656
env:
5757
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
5858

59-
- name: run migrations
59+
- name: prep for bot run
6060
if: success() && ! env.CI_SKIP
6161
timeout-minutes: 210
6262
run: |
@@ -66,9 +66,37 @@ jobs:
6666
pushd cf-graph
6767
6868
conda-forge-tick prep-auto-tick
69+
env:
70+
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
71+
RUN_ID: ${{ github.run_id }}
72+
MEMORY_LIMIT_GB: 7
73+
CF_TICK_GRAPH_DATA_BACKENDS: "${{ vars.CF_TICK_GRAPH_DATA_BACKENDS }}"
74+
MONGODB_CONNECTION_STRING: ${{ secrets.MONGODB_CONNECTION_STRING }}
75+
# emptied at the beginning and end of each run, used by Python tempdir
76+
TMPDIR: ${{ runner.temp }}
77+
78+
- name: deploy for prep
79+
if: github.ref == 'refs/heads/main' && always() && ! env.CI_SKIP
80+
run: |
81+
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
82+
83+
pushd cf-graph
84+
6985
conda-forge-tick deploy-to-github --git-only --dirs-to-deploy=pr_json,version_pr_info,pr_info
70-
conda-forge-tick auto-tick
86+
env:
87+
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
88+
RUN_ID: ${{ github.run_id }}
7189

90+
- name: run migrations
91+
if: success() && ! env.CI_SKIP
92+
timeout-minutes: 210
93+
run: |
94+
export TIMEOUT=7200
95+
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
96+
97+
pushd cf-graph
98+
99+
conda-forge-tick auto-tick
72100
env:
73101
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
74102
RUN_ID: ${{ github.run_id }}
@@ -90,7 +118,7 @@ jobs:
90118
pushd cf-graph
91119
92120
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
93-
conda-forge-tick deploy-to-github --dirs-to-ignore=pr_json
121+
conda-forge-tick deploy-to-github --dirs-to-ignore=pr_json --no-pull
94122
env:
95123
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
96124
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-feedstocks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ jobs:
7272
pushd cf-graph
7373
7474
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
75-
conda-forge-tick deploy-to-github --git-only
75+
conda-forge-tick deploy-to-github --git-only --no-pull
7676
env:
7777
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
7878
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-make-graph.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ jobs:
7575
pushd cf-graph
7676
7777
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
78-
conda-forge-tick deploy-to-github --git-only
78+
conda-forge-tick deploy-to-github --git-only --no-pull
7979
env:
8080
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
8181
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-make-migrators.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ jobs:
7575
pushd cf-graph
7676
7777
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
78-
conda-forge-tick deploy-to-github --git-only
78+
conda-forge-tick deploy-to-github --git-only --no-pull
7979
env:
8080
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
8181
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-prs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ jobs:
8282
pushd cf-graph
8383
8484
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
85-
conda-forge-tick deploy-to-github --git-only
85+
conda-forge-tick deploy-to-github --git-only --no-pull
8686
env:
8787
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
8888
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-pypi-mapping.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ jobs:
8080
pushd cf-graph
8181
8282
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
83-
conda-forge-tick deploy-to-github --git-only
83+
conda-forge-tick deploy-to-github --git-only --no-pull
8484
env:
8585
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
8686
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-update-nodes.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ jobs:
8383
pushd cf-graph
8484
8585
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
86-
conda-forge-tick deploy-to-github --git-only
86+
conda-forge-tick deploy-to-github --git-only --no-pull
8787
env:
8888
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
8989
RUN_ID: ${{ github.run_id }}
@@ -176,7 +176,7 @@ jobs:
176176
pushd cf-graph
177177
178178
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
179-
conda-forge-tick deploy-to-github --git-only
179+
conda-forge-tick deploy-to-github --git-only --no-pull
180180
env:
181181
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
182182
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-update-status-page.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ jobs:
7070
pushd cf-graph
7171
7272
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
73-
conda-forge-tick deploy-to-github --git-only
73+
conda-forge-tick deploy-to-github --git-only --no-pull
7474
env:
7575
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
7676
RUN_ID: ${{ github.run_id }}

.github/workflows/bot-versions.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ jobs:
8080
pushd cf-graph
8181
8282
export RUN_URL="https://github.com/regro/cf-scripts/actions/runs/${RUN_ID}"
83-
conda-forge-tick deploy-to-github --git-only
83+
conda-forge-tick deploy-to-github --git-only --no-pull
8484
env:
8585
BOT_TOKEN: ${{ secrets.AUTOTICK_BOT_TOKEN }}
8686
RUN_ID: ${{ github.run_id }}

conda_forge_tick/cli.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,11 @@ def make_mappings() -> None:
213213

214214

215215
@main.command(name="deploy-to-github")
216+
@click.option(
217+
"--no-pull",
218+
is_flag=True,
219+
help="Do not pull the changes to the local repo after deployment.",
220+
)
216221
@click.option(
217222
"--git-only",
218223
is_flag=True,
@@ -236,7 +241,11 @@ def make_mappings() -> None:
236241
)
237242
@pass_context
238243
def deploy_to_github(
239-
ctx: CliContext, git_only: bool, dirs_to_ignore: str, dirs_to_deploy: str
244+
ctx: CliContext,
245+
git_only: bool,
246+
dirs_to_ignore: str,
247+
dirs_to_deploy: str,
248+
no_pull: bool,
240249
) -> None:
241250
from . import deploy
242251

@@ -245,6 +254,7 @@ def deploy_to_github(
245254
git_only=git_only,
246255
dirs_to_ignore=[] if dirs_to_ignore is None else dirs_to_ignore.split(","),
247256
dirs_to_deploy=[] if dirs_to_deploy is None else dirs_to_deploy.split(","),
257+
no_pull=no_pull,
248258
)
249259

250260

0 commit comments

Comments
 (0)