Troubleshooting

"Destination repository is dirty"

Copier requires a clean git working directory:

git status
git add -A && git commit -m "WIP"
# or
git stash

"Template requires trust" Error

Configure trusted repositories or add --trust:

copier copy <template> . --trust

See Trusting Templates for permanent configuration.

Skaffold Profile Not Found

Ensure you enabled the profile during template generation. To add it later:

copier update --ask include_profile_dev_with_dependencies -a .copier-answers/devops.yaml

Recovering from Bad Merge

If you made a mistake during conflict resolution:

# Reset to pre-migration state
git checkout HEAD -- .

# Re-run copier
copier copy https://coderepo.mobilehealth.va.gov/scm/ckm/ngss-devops-template.git . --trust

Missing Auto-Detected Values

If values weren’t auto-detected, provide them manually:

copier update --ask artifact_id --ask group_id -a .copier-answers/devops.yaml

Copier Not Found

If you see an error about copier not being found:

  1. Verify Copier is installed:

    copier --version
  2. Ensure it’s in your PATH:

    which copier
  3. Install if missing:

    pipx install copier

Answers File Not Found

If you see "Skipping…​ Answers file has not been initialized":

  1. Make sure you’ve run the init goal first:

    mvn filegen:copier-init -Dcopier.template=devops
  2. Verify the answers file exists:

    ls -la .copier-answers/

Template Version Issues

To check available template versions:

git ls-remote --tags https://coderepo.mobilehealth.va.gov/scm/ckm/ngss-devops-template.git

Git Credentials Error (Docker)

If using the Docker wrapper and seeing "terminal prompts disabled":

  1. Verify ~/.git-credentials exists

  2. Check the format: https://username:token@host

  3. Ensure the file is readable

See Git Credentials for setup instructions.