Getting an Environment Variable in Terraform configuration?

I would try something more like this, which seems closer to the documentation. variable “UN” { type = string } variable “PW” { type = string } resource “google_container_cluster” “primary” { name = “marcellus-wallace” zone = “us-central1-a” initial_node_count = 3 master_auth { username = var.UN password = var.PW } node_config { oauth_scopes = [ “https://www.googleapis.com/auth/compute”, … Read more

Enable tcp\ip remote connections to sql server express already installed database with code or script(query)

I tested below code with SQL Server 2008 R2 Express and I believe we should have solution for all 6 steps you outlined. Let’s take on them one-by-one: 1 – Enable TCP/IP We can enable TCP/IP protocol with WMI: set wmiComputer = GetObject( _ “winmgmts:” _ & “\\.\root\Microsoft\SqlServer\ComputerManagement10”) set tcpProtocols = wmiComputer.ExecQuery( _ “select * … Read more

Disable rule in sonar

The right way to do is to put something like this on sonar-project.properties file per project: sonar.issue.ignore.multicriteria=e1,e2 # tab characters should not be used sonar.issue.ignore.multicriteria.e1.ruleKey=squid:S00105 sonar.issue.ignore.multicriteria.e1.resourceKey=**/*.java # right curly braces should be on a new line sonar.issue.ignore.multicriteria.e2.ruleKey=squid:RightCurlyBraceStartLineCheck sonar.issue.ignore.multicriteria.e2.resourceKey=**/*.java There are docs here on how to ignore specific rules for specific files, which links to an … Read more

Configure log4net to send errors to different appenders based on level

This can be done using the threshold or filter elements within the appender. Note that the threshold can be directly under the appender, where it acts as an inclusive filter, or under a evaluator e.g. <evaluator type=”log4net.Core.LevelEvaluator”> <threshold value=”ERROR”/> </evaluator> where it acts as an inclusive filter for skipping buffering (immediate output), where applicable. Full … Read more

How can I store a binary file in a Kubernetes ConfigMap?

Binary ConfigMaps are now supported since Kubernetes version 1.10.0. From the readme notes: ConfigMap objects now support binary data via a new binaryData field. When using kubectl create configmap –from-file, files containing non-UTF8 data will be placed in this new field in order to preserve the non-UTF8 data. Note that kubectl’s –append-hash feature doesn’t take … Read more