Skip to content

Instantly share code, notes, and snippets.

View goldyfruit's full-sized avatar
🦎

Gaëtan Trellu goldyfruit

🦎
View GitHub Profile
@goldyfruit
goldyfruit / go-build.sh
Created April 30, 2020 15:33 — forked from sivel/go-build.sh
Ansible Binary Golang Module
go build helloworld.go
GOOS=windows GOARCH=amd64 go build helloworld.go
@goldyfruit
goldyfruit / hello_qinling.py
Created June 19, 2019 15:53
Qinling - Example 5
def main(name="Qinling", region="Canada", **kwargs):
msg = "Hello {} from {} \o/".format(name, region)
return msg
@goldyfruit
goldyfruit / hello_qinling.py
Created June 19, 2019 15:03
Qinling - Example 4
def main(name="Qinling", **kwargs):
msg = "Hello {} \o/".format(name)
return msg
@goldyfruit
goldyfruit / ip_range.py
Last active June 2, 2019 17:57
Qinling - Example 3
import json
from IPy import IP
def details(cidr="192.168.0.0/24", **kwargs):
network = IP(cidr)
version = network.version()
iptype = network.iptype().lower()
reverse = network.reverseName()
prefix = network.prefixlen()
@goldyfruit
goldyfruit / hello_qinling_return.py
Created May 28, 2019 02:08
Qinling - Example 2
def main(**kwargs):
msg = "Hello Qinling \o/"
return msg
@goldyfruit
goldyfruit / hello_qinling.py
Last active May 28, 2019 01:45
Qinling - Example 1
def main(**kwargs):
print("Hello Qinling \o/")
@goldyfruit
goldyfruit / zynpass.c
Created October 27, 2018 16:35
Zyxel firmware
/* ZyXEL prestige 660HW series password calculator by brainstorm
* Thanks to http://www.adslayuda.com/Zyxel650-9.html authors
*
* Example usage:
*
* Router:
* ======
*
* ATSE
* 0028D6DF1C03

Keybase proof

I hereby claim:

  • I am goldyfruit on github.
  • I am goldyfruit (https://keybase.io/goldyfruit) on keybase.
  • I have a public key ASAN_QQz2Da2cjKdYAWjQnpMen0c9qlbEfGYszPEuA0xBQo

To claim this, I am signing this object:

@goldyfruit
goldyfruit / pcs-resources.yml
Created August 11, 2016 13:20
ansible-pacemaker resource creation
- name: Creating HAproxy cloned resource
pcs_resource:
command=create
resource_id=haproxy
type=systemd:haproxy
clone=true
clone_max=3
disable=true
args:
operations:
@goldyfruit
goldyfruit / inidata.py
Created March 4, 2016 16:04
[ansible] Add lookup plugin to parse initdata with ini_file module
# (c) 2016, Gaetan Trellu (goldyfruit) <gaetan.trellu@incloudus.com>
# (c) 2014, Pierre-Yves KERVIEL <pierreyves.kerviel@orange.com>
#
# Ansible 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, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of