Expected behavior: commits pushed to any branch without any tag do not run the job build-and-push-test
Actual behavior: all pushes without tags run the job.
What’d I miss? Yes I read other threads on this.
version: 2.1
orbs:
node: circleci/node@4.1
aws-ecr: circleci/aws-ecr@7.0.0
commands:
dotenv:
steps:
- run:
command: sh -c 'env' > .env
showenv:
steps:
- run:
command: |
echo "PRE-STEPS - env:"
cat .env
workflows:
build_and_push:
jobs:
# TEST: build+push
- aws-ecr/build-and-push-image:
checkout: false
repo: "${AWS_TEST_WEB_REPO}"
tag: "circle-${CIRCLE_TAG}"
name: build-and-push-test
filters:
tags:
only: /^test.*/
pre-steps:
- checkout
- dotenv
- run:
command: |
cat .env | sed \
# snip!
> .env
echo "NEXT_PUBLIC_IS_RUNNING_AS_TEST=true" >> .env
- showenv