Every member of the armed services has not only the right but the duty to refuse to obey an illegal order. Those giving such orders should be reported.
Every member also has the duty to obey a legal order. In opting to disobey an order an individual must be certain of the legality, or not, of the order and be prepared to accept the consequences of their action, including imprisonment.
It should be noted that conscientous objection is not a remit allowing someone not to serve, only not to kill. In WWI, WWII, Korea, Vietnam etc objectors accepted that they should serve. They filled many posts, particularly as medics and stretcher bearers, suffering heavy casualties and received numerous decorations.