How to trigger deploy command after test?

When test done. I want CI to run the file ./deploy.sh

This is my circle.yaml

deployment:
  production: # just a label; label names are completely up to you
    branch: master
    commands:
      - ./deploy.sh

This is my deploy.sh

#!/bin/sh
npm run release
scp -r -P 2222 ./dist/production/* thatilike@192.185.21.105:/home4/thatilike/public_html/thatilike.com/

Problem: CI doesn’t do aything after the tests success. It doesn’t show deploy fail or anything like that. what should I do to make CI run deploy.sh file after the tests?

This screenshot below is all it got after test

the problem is my config file circle.yaml which wrong, it should be circle.yml, therefor circle CI couldn’t read my deploy command.

1 Like

Thank you for following up @craigcosmo and sorry for the confusion!