When I run puppet code deploy
I get an object not found - no match
for id
error and code isn't deployed.
Error messages and logs
# puppet code deploy test_env --wait
Found 1 environments.
[
{
"environment": "test_env",
"error": {
"details": {
"corrected-env-name": "test_env"
},
"kind": "puppetlabs.code-manager/deploy-failure",
"msg": "Errors while deploying environment 'test_env' (exit code: 1):
\nERROR\t -> object not found - no match for id
(2f66d2486fd2269eb413dab3e3809929a358a129)\n"
},
"id": 120,
"status": "failed"
}
]
Code Manager relies on a code staging directory to deploy code. When the code staging directory is corrupted (usually by an outside application), you get this error.
Version and installation information
PE version: All supported versions
Installation type:
2018.1, 2019.1: Monolithic
2019.2 and later: Standard
Solution
To fix the error, delete the code staging directory. When the directory is deleted, Code Manager will automatically rebuild the staging directory from the control repository.
Note: Before completing these steps, check your control repository to make sure that the branch associated with the environment in the error is present.
Complete these steps on the the primary server (called the master in older versions of PE).
-
Delete the code staging directory for the environment listed in the error message. Run:
rm -rf /etc/puppetlabs/code-staging/environments/<ENVIRONMENT NAME>
-
To rebuild the staging directory, deploy the environment. Run:
puppet code deploy <ENVIRONMENT NAME> --wait
How can we improve this article?
0 comments
Please sign in to leave a comment.
Related articles