Update a container’s cpu-shares
docker update --cpu-shares 512 abebf7571666
Update a container with cpu-shares and memory
docker update --cpu-shares 512 -m 300M abebf7571666 hopeful_morse
Update a new container’s kernel memory constraints
package main | |
import ( | |
"database/sql" | |
"fmt" | |
"log" | |
_ "github.com/mattn/go-sqlite3" | |
) |
/* | |
Regex to match branch name such as | |
origin/master >> match exactly | |
origin/master1 >> Not match | |
origin/develop >> match exactly | |
origin/develop1 >> Not match | |
origin/release8.8.17 >> match |
Update a container’s cpu-shares
docker update --cpu-shares 512 abebf7571666
Update a container with cpu-shares and memory
docker update --cpu-shares 512 -m 300M abebf7571666 hopeful_morse
Update a new container’s kernel memory constraints
package main | |
import ( | |
"net/http" | |
"github.com/labstack/echo/v4" | |
) | |
type Handler struct { | |
service *Service | |
} |
CREATE TABLE IF NOT EXISTS `wp_redirection_items` ( | |
`id` int(11) unsigned NOT NULL AUTO_INCREMENT, | |
`url` mediumtext NOT NULL, | |
`match_url` VARCHAR(2000) DEFAULT NULL, | |
`match_data` TEXT, | |
`regex` INT(11) unsigned NOT NULL DEFAULT '0', | |
`position` INT(11) unsigned NOT NULL DEFAULT '0', | |
`last_count` INT(10) unsigned NOT NULL DEFAULT '0', | |
`last_access` datetime NOT NULL DEFAULT '1970-01-01 00:00:00', | |
`group_id` INT(11) NOT NULL DEFAULT '0', |
public static bool DeepEquals (this object obj, object another) | |
{ | |
if (ReferenceEquals (obj, another)) return true; | |
if ((obj == null) || (another == null)) return false; | |
if (obj.GetType ()! = another.GetType ()) return false; | |
// If the property is not a class, just int, double, DateTime, etc. v | |
// Call regular equal function | |
if (! obj.GetType (). IsClass) return obj.Equals (another); | |
version: "3.8" | |
services: | |
db: | |
image: postgres | |
container_name: local_pgdb | |
restart: always | |
ports: | |
- "5432:5432" | |
environment: | |
POSTGRES_USER: your-username |
<Project Sdk="Microsoft.NET.Sdk"> | |
<PropertyGroup> | |
<OutputType>Exe</OutputType> | |
<TargetFramework>net6.0</TargetFramework> | |
<GeneratePackageOnBuild>True</GeneratePackageOnBuild> | |
<PackAsTool>True</PackAsTool> | |
<AssemblyVersion>1.0.1.0</AssemblyVersion> | |
<FileVersion>1.0.1.0</FileVersion> | |
<Version>1.0.1</Version> | |
</PropertyGroup> |
apiVersion: v1 | |
kind: Namespace | |
metadata: | |
creationTimestamp: null | |
name: test-talos | |
spec: {} | |
status: {} | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment |
logging { | |
level = "debug" | |
format = "logfmt" | |
} | |
otelcol.receiver.otlp "example" { | |
http { | |
endpoint = "0.0.0.0:4318" | |
} |