Tutorial by Examples

docker network create -o "com.docker.network.bridge.enable_ip_masquerade"="false" lan-restricted Blocks Local LAN Internet Does not block Host running docker daemon (example access to 10.0.1.10:22)
docker network create -o "com.docker.network.bridge.enable_icc"="false" icc-restricted Blocks Containers accessing other containers on the same icc-restricted network. Does not block Access to host running docker daemon Local LAN Internet
iptables -I INPUT -i docker0 -m addrtype --dst-type LOCAL -j DROP Blocks Access to host running docker daemon Does not block Container to container traffic Local LAN Internet Custom docker networks that doesn't use docker0
docker network create --subnet=192.168.0.0/24 --gateway=192.168.0.1 --ip-range=192.168.0.0/25 local-host-restricted iptables -I INPUT -s 192.168.0.0/24 -m addrtype --dst-type LOCAL -j DROP Creates a network called local-host-restricted which which: Blocks Access to host running docker daem...
Cusom bindings should be registered by extending the current knockout bindingHandlers object.This is done by adding a new property to the object. ko.bindingHandlers.newBinding = { init: function(element, valueAccessor, allBindings, viewModel, bindingContext) { }, update: function(e...
Such Example is knowing wide spreading among PWAs (Progressive Web Applications) and in this example we're going to send a simple Backend like notification using NodeJS and ES6 Install Node-GCM Module : npm install node-gcm Install Socket.io : npm install socket.io Create a GCM Enable...
After succesfully setup Spring-Boot application all the configuration is handled in an application.properties file. You will find the file at src/main/resources/. Normally there is a need to have a database behind the application. For development its good to have a setup of dev and a prod environme...
AWK is string manipulation language, used largely in UNIX systems. The idea behind AWK was to create a versatile language to use when working on files, which wasn't too complex to understand. AWK has some other variants, but the main concept is the same, just with additional features. These other v...
To set up Node remote debugging, simply run the node process with the --debug flag. You can add a port on which the debugger should run using --debug=<port>. When your node process starts up you should see the message Debugger listening on port <port> Which will tell you that everyt...
Make sure that the NodeJS plugin is enabled Select your run configurations (screen) Select + > Node.js Remote Debug Make sure you enter the port selected above as well as the correct host Once those are configured simply run the debug target as you normally would and it will...
If you are using Sublime Text 3 then the simplest way to install Package Control is to select Install Package Control in the Tools menu or in the Command Palette and Sublime Text will install it automatically. Manually Installing: For Sublime Text 2, older versions of Sublime Text 3, or if you hav...
To track so called "virtual pageviews", use the ga('send') method right after your asynchronous request: Syntax: ga('send', 'pageview', 'path to your virtual page'); Example (Simple Link): <a href="http://example.com/my.pdf" onClick="ga('send', 'pageview', '/virtu...
Example of how ReplaceAll only applies a rule at most once, while ReplaceRepeated will do so in a loop but always restart application from the first rule. x + a /. { a_ + z :> (Print[0]; DoneA), a_ + x :> (Print[1]; y + z), a_ + y :> (Print[2]; DoneB)} (* Prints "1&quot...
import tkinter as tk root = tk.Tk() rbvar = StringVar() rbvar.set(" ") rb1 = tk.Radiobutton(root, text="Option 1", variable=rbvar, value='a', indicatoron=0) rb1.pack() rb2 = tk.Radiobutton(root, text="Option 2", variable=rbvar, value='b', indicatoron=0) rb2...
In order to run Elasticsearch, a Java Runtime Environment (JRE) is required on the machine. Elasticsearch requires Java 7 or higher and recommends Oracle JDK version 1.8.0_73. So, be sure if you have Java in your system. If not, then follow the procedure: # Install wget with yum yum -y install w...
using System.Windows; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows.Interactivity; namespace MyBehaviorAssembly { public class SliderDragEndValueBehavior : Behavior<Slider> { public static readonly DependencyProperty ValueProper...
<UserControl x:Class="Example.View" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"...
The best way to install and configure a Symfony2 project is described in the official documentation as follows: Mac OS X / Linux $ sudo curl -LsS http://symfony.com/installer -o /usr/local/bin/symfony $ sudo chmod a+x /usr/local/bin/symfony Windows c:\> php -r "file_put_contents('sym...
When you have entered something into IEx which expects a completion, such as a multiline string, IEx will change the prompt to indicate that it is waiting for you finish by changing the prompt to have an ellipsis (...) rather than iex. If you find that IEx is waiting for you to finish an expression...
How to implement Firebase Real-Time database in Android applications. Setup/Installation: First, install the Firebase SDK (guide) Register your project using the Firebase console After successfuly completing the two steps above, add the following dependency in your application level ...

Page 870 of 1336