Skip to content

Instantly share code, notes, and snippets.

View philipz's full-sized avatar

philipz philipz

View GitHub Profile
@philipz
philipz / readme.md
Last active February 12, 2021 12:07
Microk8s & Loft
  1. Need install rbac and storage by microk8s enable dns rbac storage
  2. Install loft
@philipz
philipz / Dockerfile.dev
Last active January 10, 2021 08:44
Quarkus Remote debug with Kubernetes
FROM adoptopenjdk/openjdk14-openj9:x86_64-alpine-jre-14_36.1_openj9-0.19.0
RUN apk add curl
ENV QUARKUS_LAUNCH_DEVMODE=true \
JAVA_ENABLE_DEBUG=true
COPY target/quarkus-app/lib/ /deployments/lib/
COPY target/quarkus-app/*.jar /deployments/
COPY target/quarkus-app/app/ /deployments/app/
COPY target/quarkus-app/quarkus/ /deployments/quarkus/
@philipz
philipz / readme.md
Created January 5, 2021 06:42
Kubectl notes

Update images

kubectl set image -n wellness-dev deploy/micrometer quarkus-micrometer=philipz/quarkus-micrometer:1

@philipz
philipz / readme.md
Last active January 2, 2021 16:47
TiDB OnTime Dataset loading

Ref: Could you provide an example to load big dataset like Percona?

# SET GLOBAL sql_mode = ''
for y in `seq 1987 2018`
do
for i in `seq 1 12`
do
echo "$y - $i"
mysql --local-infile=1 -h 127.0.0.1 -P 4000  -u root -e "load data local infile '/home/philipz/otp/On_Time_On_Time_Performance_${y}_${i}.csv' into table otp.ontime fields terminated by ',' OPTIONALLY ENCLOSED BY '\"' ignore 1 lines"
done
@philipz
philipz / upx.md
Created December 13, 2020 15:28
UPX compression

upx --best -k kafka-quickstart-1.0-SNAPSHOT-runner

@philipz
philipz / gist:4f4e74d4ea516c7a369cdfd68c2fee13
Created November 22, 2020 05:10
How to Hide Grub Boot Menu in Ubuntu 20.04 LTS
sudo nano /etc/default/grub
add this line to your grub file:
GRUB_RECORDFAIL_TIMEOUT=0
sudo update-grub
Done!
@philipz
philipz / readme.md
Created February 12, 2020 05:18
Change Quarkus Default GraalVM Version

./mvnw package -Pnative -Dquarkus.native.container-runtime=docker -Dquarkus.native.builder-image=quay.io/quarkus/ubi-quarkus-native-image:19.3.1-java8

@philipz
philipz / gist:71323be0c2362c6717c64e07d174c149
Created January 24, 2020 14:22
VSCode Java Remote Debug
{
"type": "java",
"name": "backend",
"request": "attach",
"hostName": "localhost",
"port": 5005
},
@philipz
philipz / readme.md
Last active December 15, 2019 13:12
Apache Ignite architecture model

Apache Ignite architecture model

Embedded with the application

ignite_arch1

Server in separate JVM (real cluster topology)

ignite_arch2

Client and Server in separate JVM on single host

ignite_arch3

@philipz
philipz / ignite-stateful-set.yaml
Last active December 27, 2019 06:06
Apache Ignite Transactions Test
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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