Skip to content

Instantly share code, notes, and snippets.

View dqminh's full-sized avatar

Daniel, Dao Quang Minh dqminh

View GitHub Profile
#!/bin/sh
# Run Chrome in a container
runtime=$1
ARGS="--net host"
if [ -z $runtime ]; then
ARGS="${ARGS}"
else
echo "running with $runtime"
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3c1a689..7603e6e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -25,7 +25,8 @@ option(JAEGERTRACING_WARNINGS_AS_ERRORS "Treat compiler warnings as errors" OFF)
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR
CMAKE_CXX_COMPILER_ID MATCHES "Clang")
- set(cxx_flags -Wall -pedantic)
+ set(cxx_flags -Wall -pedantic -static-libasan -fsanitize=address -fno-omit-frame-pointer)
package benchzstd
import (
"bytes"
"io/ioutil"
"testing"
"github.com/DataDog/zstd"
"github.com/valyala/gozstd"
)
❯ sudo cilium status
Allocated IPv4 addresses:
10.1.0.1
10.1.0.2
10.1.0.3
10.1.0.4
10.1.0.5
10.1.0.6
10.1.0.7
10.1.0.8
zipkin_1 | 2016-04-13 16:56:37.062 ERROR 1 --- [nio-9411-exec-7] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.jooq.exception.DataAccessException: SQL [select distinct `zipkin_spans`.`trace_id` from `zipkin_spans` join `zipkin_annotations` on (`zipkin_spans`.`trace_id` = `zipkin_annotations`.`trace_id` and `zipkin_spans`.`id` = `zipkin_annotations`.`span_id`) where (`zipkin_annotations`.`endpoint_service_name` = ? and `zipkin_spans`.`start_ts` between ? and ?) order by `zipkin_spans`.`start_ts` desc limit ?]; Expression #1 of ORDER BY clause is not in SELECT list, references column 'zipkin.zipkin_spans.start_ts' which is not in SELECT list; this is incompatible with DISTINCT] with root cause
zipkin_1 |
zipkin_1 | org.mariadb.jdbc.internal.util.dao.QueryException: Expression #1 of ORDER BY clause is not in SELECT list, references column 'zipkin.zipkin_spans.start_ts' which
package main
import (
"log"
"os"
"os/exec"
"time"
)
func main() {
diff --git a/vendor/src/github.com/docker/libcontainer/process_linux.go b/vendor/src/github.com/docker/libcontainer/process_linux.go
index 1c74b65..fc9a733 100644
--- a/vendor/src/github.com/docker/libcontainer/process_linux.go
+++ b/vendor/src/github.com/docker/libcontainer/process_linux.go
@@ -127,12 +127,13 @@ func (p *setnsProcess) terminate() error {
}
func (p *setnsProcess) wait() (*os.ProcessState, error) {
- err := p.cmd.Wait()
- if err != nil {
+
+func TestExecinPassExtraFiles(t *testing.T) {
+ if testing.Short() {
+ return
+ }
+ rootfs, err := newRootfs()
+ if err != nil {
+ t.Fatal(err)
+ }
+ defer remove(rootfs)
docker git:master ❯ sudo service docker restart
docker stop/waiting
docker start/running, process 19816
docker git:master ❯ cat /proc/sys/net/ipv4/ip_local_port_range
32768 61000
docker git:master ❯ docker run -P -p 80 -p 32768:8080 -d busybox top
6315c5cb8192e6d414065c73967605eccf48c1976c4c541a9e8afb6af0fd8aad
FATA[0000] Error response from daemon: Cannot start container 6315c5cb8192e6d414065c73967605eccf48c1976c4c541a9e8afb6af0fd8aad: Bind for 0.0.0.0:32768 failed: port is already allocated
--- FAIL: TestExecAfterDaemonRestart (11.59s)
docker_utils.go:148: waiting for daemon to start
docker_utils.go:190: daemon started
docker_utils.go:136: exiting daemon
docker_utils.go:148: waiting for daemon to start
docker_utils.go:190: daemon started
docker_cli_exec_test.go:184: Could not start top after daemon restart: err=exit status 1
Error response from daemon: Cannot start container top: [0] Id already in use: Container with id exists: 68b45ea6f54b940a6be6320002b67fc155c92ee92a9627e2d01f09b506600790
time="2015-03-16T18:47:21Z" level=fatal msg="Error: failed to start one or more containers"
docker_utils.go:136: exiting daemon