8000 Fixes #26874: Add a command to reset package cache by peckpeck · Pull Request #416 · Normation/rudder-agent · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fixes #26874: Add a command to reset package cache #416

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion share/commands/agent-reset
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
# @man +
# @man *Options*:
# @man +
# @man *-p*: just reset the package cache and nothing else
# @man +
# @man *-i*: run the agent in information mode, prints basic information
# @man +
# @man *-q*: run the agent in quiet mode (display only error messages)
Expand All @@ -23,7 +25,7 @@ VERBOSITY=""
VERBOSE=false
QUIET=false

while getopts "iIvdqc" opt; do
while getopts "iIvdqcp" opt; do
case $opt in
i|I)
VERBOSITY="-I ${INFO_CLASS}"
Expand All @@ -49,6 +51,12 @@ while getopts "iIvdqc" opt; do
COLOR=""
clear_colors
;;
p)
# - remove state
[ "$VERBOSE" = true ] && echo "Resetting package cache..."
rm -f ${RUDDER_VAR}/cfengine-community/state/package_*
exit $?
;;
esac
done

Expand Down
0