RFE: Some way to confirm a custom script has completed

Bug #1949239 reported by Mark Cunningham
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Landscape Server
New
Undecided
Unassigned

Bug Description

Problem:
A custom script is being used to do the equivalent of a do-release-upgrade for machines that use a local Landscape mirror and have limited network access. The script does not reliably report back success or failure (likely because the landscape-client is upgraded and the client service restarted as part of the upgrade).

To work around this, a curl command was added to the custom script that creates an entry in the Apache logs on the Landscape server. The client machine is then able, as part of the script, to somewhat independent of the landscape-client send a reply saying that the script has completed:

```
#!/bin/bash

sudo su - -c "
export DEBIAN_FRONTEND=noninteractive
apt-get clean
apt-get update
apt-get install -y --only-upgrade apt

apt-get -o Dpkg::Options::=--force-confold -o Dpkg::Options::=--force-confdef -y --allow-unauthenticated dist-upgrade"

curl -s http://<landscape-server>/upgrade-completed_${HOSTNAME}_$(lsb_release -rs)
```

This then shows up in the apache log under: /var/log/apache2/landscape_access.log, but the landscape-server is unaware of this. The request here would be for either some way to have Landscape alert or be aware of such a custom reply from a script for better reliably noting if a custom script had completed its task or not.

Not entirely sure if this would be possible, but made sense to make the feature request either way.

information type: Proprietary → Public
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.