./redis.shtest the redis cluster
| if _, err := os.Stat("/path/to/whatever"); os.IsNotExist(err) { | |
| // path/to/whatever does not exist | |
| } | |
| if _, err := os.Stat("/path/to/whatever"); !os.IsNotExist(err) { | |
| // path/to/whatever exists | |
| } |
| // Copyright 2014 Google Inc. All Rights Reserved. | |
| // | |
| // Licensed under the Apache License, Version 2.0 (the "License"); | |
| // you may not use this file except in compliance with the License. | |
| // You may obtain a copy of the License at | |
| // | |
| // http://www.apache.org/licenses/LICENSE-2.0 | |
| // | |
| // Unless required by applicable law or agreed to in writing, software | |
| // distributed under the License is distributed on an "AS IS" BASIS, |
| ##based on Mesosphere Marathon's servicerouter.py haproxy config | |
| global | |
| daemon | |
| log 127.0.0.1 local0 | |
| log 127.0.0.1 local1 notice | |
| maxconn 4096 | |
| tune.ssl.default-dh-param 2048 | |
| defaults |
| %% Copyright 2020 Alexander Yakushev | |
| % | |
| % This work may be distributed and/or modified under the | |
| % conditions of the LaTeX Project Public License, either version 1.3 | |
| % of this license or (at your option) any later version. | |
| % The latest version of this license is in | |
| % http://www.latex-project.org/lppl.txt | |
| % and version 1.3 or later is part of all distributions of LaTeX | |
| % version 2005/12/01 or later. | |
| % |
| package main | |
| import ( | |
| "bytes" | |
| "encoding/json" | |
| "github.com/gin-gonic/gin" | |
| "golang.org/x/oauth2" | |
| "golang.org/x/oauth2/bitbucket" | |
| "golang.org/x/oauth2/github" | |
| "golang.org/x/oauth2/google" |
| # taken from http://www.piware.de/2011/01/creating-an-https-server-in-python/ | |
| # generate server.pem with the following command: | |
| # openssl req -new -x509 -keyout server.pem -out server.pem -days 365 -nodes | |
| # change to the directory you want to serve and run as follows: | |
| # python simple-https-server.py | |
| # then in your browser, visit: | |
| # https://localhost:4443 | |
| # to add the certificate to Chrome see: | |
| # http://stackoverflow.com/a/15076602/526860 | |
| import BaseHTTPServer |
| #!/bin/sh | |
| # Usage: | |
| # wget -O- https://gist.githubusercontent.com/ifduyue/dea03b4e139c5758ca114770027cf65c/raw/install-proxychains-ng.sh | sudo bash -s | |
| set -eu | |
| version=4.14 | |
| wget https://github.com/rofl0r/proxychains-ng/archive/v$version.tar.gz | |
| tar xf v$version.tar.gz |
| package main | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "reflect" | |
| ) | |
| type Something interface{} |
| #!/bin/bash | |
| # | |
| # Docker Daemon varsayilan olarak ag iletisimi olmadan | |
| # sadece Unix socket uzerinden calismaktadir. | |
| # Docker Client ve Daemon arasinda HTTPS uzerinden | |
| # guvenli iletisimin kurulmasi icin TLS aktif hale getirilmelidir. | |
| # Client ve Server/daemon arasindaki guvenli iletisim agi | |
| # icin gereken client ve server sertifikasyonlarini | |
| # olusturmaliyiz. | |
| # |