This file contains hidden or 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
| begin | |
| require 'bundler/inline' | |
| rescue LoadError => e | |
| $stderr.puts 'Bundler version 1.10 or later is required.' | |
| raise e | |
| end | |
| gemfile(true) do | |
| source 'https://rubygems.org' | |
| gem 'rom' |
This file contains hidden or 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
| - hosts: workers | |
| gather_facts: no | |
| pre_tasks: | |
| - set_fact: sequence_number="{{ ansible_default_ipv4['macaddress'].split(':')[-1] | int('', 16) }}" | |
| - set_fact: daemons_count="{{ groups['daemons'] | length }}" | |
| - set_fact: daemon_i='{{ (sequence_number|int) % (daemons_count|int)}}' | |
| - set_fact: daemon_host="{{ hostvars[groups['daemons'][daemon_i|int]]['ansible_eth0']['ipv4']['address'] }}" | |
| - debug: var=daemon_i | |
| roles: | |
| - role: worker |
This file contains hidden or 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
| begin | |
| require 'bundler/inline' | |
| rescue LoadError => e | |
| $stderr.puts 'Bundler version 1.10 or later is required.' | |
| raise e | |
| end | |
| gemfile(true) do | |
| source 'https://rubygems.org' | |
| gem 'rom' |
This file contains hidden or 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
| begin | |
| require 'bundler/inline' | |
| rescue LoadError => e | |
| $stderr.puts 'Bundler version 1.10 or later is required.' | |
| raise e | |
| end | |
| gemfile(true) do | |
| source 'https://rubygems.org' | |
| gem 'rom' |
This file contains hidden or 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
| begin | |
| require 'bundler/inline' | |
| rescue LoadError => e | |
| $stderr.puts 'Bundler version 1.10 or later is required.' | |
| raise e | |
| end | |
| gemfile(true) do | |
| source 'https://rubygems.org' | |
| gem 'rom', git: 'https://github.com/rom-rb/rom.git' |
This file contains hidden or 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
| module RomInterface | |
| def self.extended(klass) | |
| klass.extend ROM::ClassMacros | |
| klass.defines :relation, :register_as | |
| end | |
| def base_relation | |
| relation | |
| end |
This file contains hidden or 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
| // ==UserScript== | |
| // @name Poland Visa Applicator | |
| // @namespace http://e-konsulat.gov.pl/ | |
| // @version 0.1 | |
| // @description Brute Force the visa application page | |
| // @author Serhii Kukunin <[email protected]> | |
| // @match https://secure.e-konsulat.gov.pl/Uslugi/RejestracjaTerminu.aspx* | |
| // @grant none | |
| // @ |
This file contains hidden or 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
| unless File.exist?('Gemfile') | |
| File.write('Gemfile', <<-GEMFILE) | |
| source 'https://rubygems.org' | |
| gem 'rails', github: 'rails/rails' | |
| gem 'arel', github: 'rails/arel' | |
| gem 'rack', github: 'rack/rack' | |
| gem 'i18n', github: 'svenfuchs/i18n' | |
| gem 'carrierwave', github: 'carrierwaveuploader/carrierwave' | |
| gem 'sqlite3' | |
| GEMFILE |
This file contains hidden or 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
| unless File.exist?('Gemfile') | |
| File.write('Gemfile', <<-GEMFILE) | |
| source 'https://rubygems.org' | |
| gem 'rails', github: 'rails/rails' | |
| gem 'arel', github: 'rails/arel' | |
| gem 'rack', github: 'rack/rack' | |
| gem 'i18n', github: 'svenfuchs/i18n' | |
| gem 'sqlite3' | |
| GEMFILE |
This file contains hidden or 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
| function addAllResourcesLoadedCallback(page, timeout) { | |
| function debug(text) { | |
| if (typeof page.onDebug == "function") { | |
| page.onDebug(text); | |
| } | |
| } | |
| var counter = [], timer; | |
| timeout = timeout || 2000; |
NewerOlder