Load key "/root/.ssh/id_dsa": invalid format

I am following the tutorial to learn how to set up CI/CD to deploy my app to the remote server.
The deploy job failed with the following logs:

$ mkdir -p ~/.ssh
$ echo "$SSH_PRIVATE_KEY" >> ~/.ssh/id_dsa
$ chmod 600 ~/.ssh/id_dsa
$ echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config
$ rsync -rav --delete dist/ gitlab@777.777.777.777:~/vue-ci/
Warning: Permanently added '777.777.777.777' (ED25519) to the list of known hosts.
Load key "/root/.ssh/id_dsa": invalid format
Permission denied, please try again.
Permission denied, please try again.
gitlab@777.777.777.777: Permission denied (publickey,password).
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(228) [sender=3.2.3]
Cleaning up project directory and file based variables 00:01
ERROR: Job failed: exit code 12

Thanks in advance