Skip to content

Instantly share code, notes, and snippets.

View tnt's full-sized avatar

Thelonius Kort tnt

  • openthinclient gmbh
  • Dresden, Germany
View GitHub Profile
root@opsidemo:~# tree /etc/nagios3/conf.d/
/etc/nagios3/conf.d/
|-- contacts_nagios2.cfg
|-- extinfo_nagios2.cfg
|-- generic-host_nagios2.cfg
|-- generic-service_nagios2.cfg
|-- hostgroups_nagios2.cfg
|-- localhost_nagios2.cfg
|-- opsi
| |-- clients
...
2014-07-27 16:54:20,277::INFO::[SABnzbd:1523] Starting web-interface on 0.0.0.0:8080
2014-07-27 16:54:20,279::INFO::[_cplogging:201] [27/Jul/2014:16:54:20] ENGINE Bus STARTING
2014-07-27 16:54:20,290::INFO::[_cplogging:201] [27/Jul/2014:16:54:20] ENGINE Started monitor thread '_TimeoutMonitor'.
2014-07-27 16:54:20,402::INFO::[_cplogging:201] [27/Jul/2014:16:54:20] ENGINE Serving on ::1:8080
2014-07-27 16:54:20,508::INFO::[_cplogging:201] [27/Jul/2014:16:54:20] ENGINE Serving on 0.0.0.0:8080
2014-07-27 16:54:20,510::INFO::[_cplogging:201] [27/Jul/2014:16:54:20] ENGINE Bus STARTED
Traceback (most recent call last):
File "SABnzbd.py", line 1895, in <module>
main()
thelonius@thelonius-VirtualBox:~/dresden-weekly/ansible-rails-example$ ./remote.sh
Updating apt cache
Installing Ansible dependencies and Git
Reading package lists... Done
Building dependency tree
Reading state information... Done
git is already the newest version.
The following extra packages will be installed:
libyaml-0-2 python-markupsafe
Suggested packages:
thelonius@thelonius-VirtualBox:~/dresden-weekly/ansible-rails-example$ ./remote.sh
Using Ansible from /opt/ansible v1.8.2
Setting up Ansible to run out of checkout...
PATH=/opt/ansible/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
PYTHONPATH=/opt/ansible/lib
MANPATH=/opt/ansible/docs/man:
Remember, you may wish to specify your host file with -i
@tnt
tnt / gist:eedaed9a6cc75130b9cb
Last active August 29, 2015 14:16
Strange ansible output of test with partially faked hosts and keys - https://github.com/tnt/ansible-gpg-keys-mod
On precise32 instead of the second (fake) key, the first key is processed again.
UPDATE: Everything works fine with sane key ids (https://gist.github.com/tnt/70b116c72be11dc3cc66)
_____________________________________________________________________________
# gpg_keys_mod_test.yml:
---
- hosts: [ precise32, centos-7 ]
vars:
gpg_key_server_urls:
@tnt
tnt / gist:70b116c72be11dc3cc66
Created February 27, 2015 18:34
gpg 1.4.11 with invalid key ids
vagrant@precise32:~$ gpg --recv-keys 409B6B1796C275362A1703113804BB82D39DC0E3
gpg: requesting key D39DC0E3 from hkp server keys.gnupg.net
gpg: key D39DC0E3: public key "Michal Papis (RVM signing) <mpapis@gmail.com>" imported
gpg: no ultimately trusted keys found
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)
vagrant@precise32:~$ gpg --list-keys
vagrant@precise32:~$ gpg --recv-keys 409B6B1796C275362AFFFF113804BB82D39DC0E3
gpg: requesting key D39DC0E3 from hkp server keys.gnupg.net
gpg: key D39DC0E3: public key "Michal Papis (RVM signing) <mpapis@gmail.com>" imported
diff --git a/ansible/plays/provision.yml b/ansible/plays/provision.yml
index bdc1e20..ed5011e 100644
--- a/ansible/plays/provision.yml
+++ b/ansible/plays/provision.yml
@@ -8,6 +8,9 @@
- role: debops.users
users: yes
users_list:
+ - name: 'www-data'
+ groups:
diff --git a/ansible/centos-specifics.sh b/ansible/centos-specifics.sh
new file mode 100644
index 0000000..9a23d57
--- /dev/null
+++ b/ansible/centos-specifics.sh
@@ -0,0 +1,27 @@
+function package_update_cache {
+ local FORCE=$1
+ CU_TIME_FILE=/tmp/yum_last_upd_cch
+ if [ -n "$FORCE" ] || [ ! -f $CU_TIME_FILE ] || [ $(date +%s) -gt $(($(date -r $CU_TIME_FILE +%s) + 3600)) ]; then
diff --git a/firewalld/tasks/main.yml b/firewalld/tasks/main.yml
index 2387387..d045654 100644
--- a/firewalld/tasks/main.yml
+++ b/firewalld/tasks/main.yml
@@ -1,19 +1,19 @@
---
-- name: Enable/disable firewalld - RedHat
+- name: RedHat | Enable/disable firewalld
service:
name: firewalld
GEM
remote: http://rubygems.org/
specs:
charlock_holmes (0.7.3)
creole (0.5.0)
diff-lcs (1.3)
gemojione (3.2.0)
json
github-markdown (0.6.9)
github-markup (1.6.0)