This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# Quick script to check your Dell asset's warranty status | |
# Just drop your service tag as parameters for the script and go. | |
import sys | |
import requests | |
APIKEY = 'd676cf6e1e0ceb8fd14e8cb69acd812d' | |
URL = 'https://api.dell.com/support/v2/assetinfo/warranty/tags.json?svctags={0}&apikey=' + APIKEY |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# Script to query Dell's API for the hardware's original config. | |
# Just drop your service tag as parameters for the script and go. | |
import sys | |
import requests | |
APIKEY = 'd676cf6e1e0ceb8fd14e8cb69acd812d' | |
URL = 'https://api.dell.com/support/v2/assetinfo/detail/tags.json?svctags={0}&apikey=' + APIKEY |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (C) Cfengine AS | |
# This file is part of Cfengine 3 - written and maintained by Cfengine AS. | |
# This program is free software; you can redistribute it and/or modify it | |
# under the terms of the GNU General Public License as published by the | |
# Free Software Foundation; version 3. | |
# This program is distributed in the hope that it will be useful, | |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
body common control { bundlesequence => { "example1", "example2" }; } | |
bundle agent example1 | |
{ | |
vars: | |
"myarray[0]" string => "bla1"; | |
"myarray[1]" string => "bla2"; | |
"myarray[3]" string => "bla"; | |
classes: | |
"ok" expression => regarray("myarray","b.*2"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
''' | |
Superglue to keep /etc/hosts up-to-date of given entries. | |
If the entry doesn't exists, we won't add it. We only keep | |
the EXISTING entries updated. | |
* depends on python-dnspython |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
body common control { bundlesequence => { "example" }; } | |
bundle agent example { | |
vars: | |
"foo[1]" string => "foo[1]"; | |
"foo[2]" string => "foo[2]"; | |
"foo[default]" string => "foo[default]"; | |
"randomvar" string => "foobar"; | |
secondpass:: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
body common control | |
{ | |
bundlesequence => { "test_apt" }; | |
inputs => { "cfengine_stdlib.cf" }; | |
} | |
bundle agent test_apt | |
{ | |
vars: | |
"curver" string => "23.3+1-1ubuntu9.2"; |