From 058fb3df9e85946f21409c17b19b4265f4c3152e Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Sun, 11 Aug 2024 01:32:48 +0200 Subject: [PATCH 01/10] Create docs workflow --- .github/workflows/docs.yml | 55 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 .github/workflows/docs.yml diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 000000000..71557ed67 --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,55 @@ +name: Publish Docs + +on: + workflow_dispatch: # allow manual runs + push: + branches: + - master + paths: # avoid extra builds + - docs/** + - .github/workflows/docs.yml + +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: github-pages + cancel-in-progress: false # skip any intermediate builds but let finish + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: 3.9 + - id: pages + uses: actions/configure-pages@v4 + - name: Install requirements + run: | + python -m venv .venv + source .venv/bin/activate + curl -sSL https://install.python-poetry.org | python - + poetry config virtualenvs.create false + poetry install --extras docs --no-interaction --verbose --no-ansi + echo "$VIRTUAL_ENV/bin" >> $GITHUB_PATH + echo "VIRTUAL_ENV=$VIRTUAL_ENV" >> $GITHUB_ENV + - name: Make docs + run: | + cd docs + make html + - uses: actions/upload-pages-artifact@v3 + with: + path: docs/_build/html + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest + needs: build + steps: + - id: deployment + uses: actions/deploy-pages@v4 From 4b0b055d6a22444a3120e58ef857b89a364ff2d4 Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Sun, 11 Aug 2024 01:59:51 +0200 Subject: [PATCH 02/10] Bump versions --- docs/conf.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 0ba9eacad..8e10d6fc8 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -41,7 +41,7 @@ # General information about the project. project = "Normandy" -copyright = "2016-2018, Mozilla Foundation" +copyright = "2016-2024, Mozilla Foundation" author = "Mozilla Foundation" # The version info for the project you're documenting, acts as replacement for @@ -49,9 +49,9 @@ # built documents. # # The short X.Y version. -version = "0.1.0" +version = "1.146" # The full version, including alpha/beta/rc tags. -release = "0.1.0" +release = "1.146.1" # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. From 0067590a5c14216d74712c1d2009d1302e4bc1bb Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Sun, 11 Aug 2024 04:11:52 +0200 Subject: [PATCH 03/10] Sync version with pyproject/poetry --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 798419bbe..2a6bcd149 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ line-length = 99 [tool.poetry] name = "normandy" -version = "1.133.0" +version = "1.146.1" description = "Firefox recipe server" authors = ["Your Name "] license = "MPL-2.0" From ff0ad00f774a8ec5bc8a94ac7f53734d73acf6cc Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Sun, 11 Aug 2024 04:14:50 +0200 Subject: [PATCH 04/10] Always rebuild docs --- .github/workflows/docs.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 71557ed67..e0c55de20 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -5,9 +5,6 @@ on: push: branches: - master - paths: # avoid extra builds - - docs/** - - .github/workflows/docs.yml permissions: contents: read From 3d7c017f66579a167a67b2121f71dec99a93c844 Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Sun, 11 Aug 2024 20:18:08 +0200 Subject: [PATCH 05/10] Install poetry with runner pip --- .github/workflows/docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e0c55de20..19b20a45b 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -29,7 +29,7 @@ jobs: run: | python -m venv .venv source .venv/bin/activate - curl -sSL https://install.python-poetry.org | python - + pip install poetry poetry config virtualenvs.create false poetry install --extras docs --no-interaction --verbose --no-ansi echo "$VIRTUAL_ENV/bin" >> $GITHUB_PATH From 1c73146ade334c292ce10b1b1de91cdf4aaea90d Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Sun, 11 Aug 2024 21:22:25 +0200 Subject: [PATCH 06/10] Bump configure-pages --- .github/workflows/docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 19b20a45b..a97bad35f 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -24,7 +24,7 @@ jobs: with: python-version: 3.9 - id: pages - uses: actions/configure-pages@v4 + uses: actions/configure-pages@v5 - name: Install requirements run: | python -m venv .venv From a873100a3d27d7053a5443073a5f4342cb93abb6 Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Tue, 13 Aug 2024 21:31:43 +0200 Subject: [PATCH 07/10] Install via pipx --- .github/workflows/docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a97bad35f..cabd53371 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -29,7 +29,7 @@ jobs: run: | python -m venv .venv source .venv/bin/activate - pip install poetry + pipx install poetry poetry config virtualenvs.create false poetry install --extras docs --no-interaction --verbose --no-ansi echo "$VIRTUAL_ENV/bin" >> $GITHUB_PATH From 829e9f86564bc831d07c41667d7559bbaa691f65 Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Tue, 13 Aug 2024 21:45:29 +0200 Subject: [PATCH 08/10] Bump version in docs --- docs/conf.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 8e10d6fc8..6061b6e44 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -49,9 +49,9 @@ # built documents. # # The short X.Y version. -version = "1.146" +version = "1.147" # The full version, including alpha/beta/rc tags. -release = "1.146.1" +release = "1.147.0" # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. From 4ebe278466e98a7572b772ce6bc3e7f524eb1ddc Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Tue, 13 Aug 2024 21:50:58 +0200 Subject: [PATCH 09/10] Bump normandy version This version is already tagged and running in prod, just making sure it's also correctly output upon installing. --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a6bcd149..2cbb7d301 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ line-length = 99 [tool.poetry] name = "normandy" -version = "1.146.1" +version = "1.147.0" description = "Firefox recipe server" authors = ["Your Name "] license = "MPL-2.0" From b05d1a62947219ff1a2271a0b12f436174542fb2 Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Tue, 13 Aug 2024 22:07:48 +0200 Subject: [PATCH 10/10] Remove docs-publish from circleci config Deployment now handled via GHA; build to test is kept in the pipeline. --- .circleci/config.yml | 35 +---------------------------------- 1 file changed, 1 insertion(+), 34 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b78d3d58e..ab3f33ad4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,7 +3,6 @@ # DOCKERHUB_REPO - docker hub repo, format: / # DOCKER_USER # DOCKER_PASS -# version: 2.1 @@ -157,32 +156,6 @@ jobs: - store_artifacts: path: docs/_build/html - docs-publish: - docker: - - image: node:10 - auth: - username: $DOCKER_USER - password: $DOCKER_PASS - steps: - - checkout - - attach_workspace: - at: docs/_build - - run: - name: Install and configure dependencies - command: | - yarn install --frozen-lockfile - git config user.email "ci-build@normandy.mozilla.org" - git config user.name "ci-build" - - run: - name: Disable jekyll builds - command: touch docs/_build/html/.nojekyll - - add_ssh_keys: - fingerprints: - - "5d:91:56:44:f2:f7:57:2a:29:88:f0:2e:37:fe:86:2a" - - run: - name: Deploy docs to gh-pages - command: yarn gh-pages --dotfiles --message "[skip ci] Docs updates" --dist docs/_build/html - python-tests: docker: - image: cimg/python:3.9.12-node @@ -217,7 +190,7 @@ jobs: name: Python tests command: | mkdir test-reports - py.test normandy \ + pytest normandy \ --tb=short -vvv \ --junitxml=test-reports/junit.xml - store_test_results: @@ -267,12 +240,6 @@ workflows: # Group: Publish # All of these should only run on master and tags - - docs-publish: - requires: - - docs-build - filters: - branches: - only: master - docker-image-publish: requires: - python-tests