Running nightly on a specified git tag


#1

Running nightly on master does work for us, but usually master might have unreleased changes. So to test the latest stable would need to run nightly builds on tags. Since dynamically I cannot pick the latest tag in circleci, so we decided to tag always the latest stable as vLATEST.

What I tried so far:

nightly_build:
  triggers:
    - schedule:
        cron: "00 23 * * *"
        filters:
          branches:
            only:
              - master
  jobs:
    - nightly_build
nightly_build_for_latest:
  triggers:
    - schedule:
        cron: "00 22 * * *"
        filters:
          tags:
            only: "vLATEST"
  jobs:
    - nightly_build

and

nightly_build:
  triggers:
    - schedule:
        cron: "00 23 * * *"
        filters:
          branches:
            only:
              - master
          tags:
            only: "vLATEST"
  jobs:
    - nightly_build

None of these works, the first says:

Encountered errors trying to create workflows from this config: Config does not conform to schema: {:workflows {:nightly_build {:triggers [{:schedule {:filters {:tags disallowed-key}}}]}}}

While the latter says if I run circleci config validate -c .circleci/config.yml:

  Error: Error parsing config file: yaml: line 202: did not find expected key 

I guess it tried to find the branches key.

The docs do not mention tags but do not say it cannot be used, see https://circleci.com/docs/2.0/workflows/#specifying-a-valid-schedule

By the way the project is open source: https://github.com/purposeindustries/intellyo-application-design-system


#2