1970s-1980s movie. Man has a headjack/socket/port/connector back in his head (or neck)

I think it’s a sci-fi movie . I remember a woman and a man inside a Spaceship (or colony in a planet) and the man has a headjack in his back head (similar to ports in The Matrix), but not the woman. At the end of the movie, the man (with beard) fights against other man/cyborg/monster and only woman survived.

Thank you in advance.

1998’s Soldier? Soldier (1998) Official Trailer - Kurt Russell, Jason Scott Lee Movie HD - YouTube