技术
dns server
apt install dnsmasq
vi /etc/dnsmasq.conf
1 2 3 4 | server=8.8.8.8 server=114.114.114.114 address=/keycloak.euhat.com/192.168.188.134 |
sudo systemctl restart dnsmasq
端口转发利器socat
1 | sudo socat TCP-LISTEN:80,fork TCP:localhost:8848 |
把Docker当沙盒用
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | sudo docker run -itd \ --name srv1 \ -v /mnt/hgfs/share:/home/work/share \ -p 9083:9083 \ fedora:latest \ /bin/bash sudo docker exec -it srv1 /bin/bash sudo docker stop srv1 #sudo docker start srv1 sudo docker rm srv1 sudo docker rmi fedora:latest sudo docker system df -v sudo docker ps -a --filter volume=<volume_name> |
Vue3 自定义组件传参
父组件
1 2 3 4 5 6 7 8 9 | <template> <HelloWor v-model:aaa="foo" /> {{foo}} </template> <script setup> import HelloWor from './Hello.vue' import{ref}from 'vue' const foo=ref() </script> |
子组件
1 2 3 4 5 6 7 8 9 10 11 | <template> <input v-model="yyy" /> </template> <script setup> import{useAttrs,computed}from 'vue' const attrs = useAttrs() const emit = defineEmits(['update:aaa'])//v-model父传子必须要用emit声明,否则父的v-model修饰符会不起作用。 const yyy=computed({ get() {return attrs.aaa}, set(newV) {emit('update:aaa',newV)}}) </script> |
Vue Memo
node.js installation,
https://nodejs.org/en/download/prebuilt-installer
config file - C:\Users\euhat\.npmrc
vue.js installation,
npm config set registry https://registry.npmmirror.com/
npm install -g @vue/cli
first programming,
cd project_parent
vue create test
Share Folder Names In VM Guest
\\VBoxSvr\\mnt
\\vmware-host\Shared Folders\D
Visit Guest Service From Host With VirtualBox
VBoxManage modifyvm "xubuntu" --natpf1 "guest-redis,tcp,,6379,,6379"
VBoxManage modifyvm "xubuntu" --natpf1 "guest-mysql,tcp,,3306,,3306"
Another method is to create two adapters, NAT + Host Only.
ps. Delete the forwarding rules like:
VBoxManage modifyvm "xubuntu" --natpf1 delete "guest-redis"
refer to:
https://blog.csdn.net/chinainvent/article/details/6234368
https://superuser.com/questions/1282666/host-cant-connect-to-guest-with-nat-networking-at-virtualbox-but-others
https://forums.virtualbox.org/viewtopic.php?t=32014
Arthas Memo
dashboard thread -b # check dead lock thread thread 123 jad TestClass redefine /root/TestClass.class jmap -histo 1234 | head -20 |
refer to:
https://visualvm.github.io/index.html
IDEA Maven Speedup
ideaIU-2023.2.1.win\plugins\maven\lib\maven3\conf\settings.xml
<mirrors> ... <mirror> <id>aliyunmaven</id> <mirrorOf>*</mirrorOf> <name>阿里云公共仓库</name> <url>https://maven.aliyun.com/repository/public</url> </mirror> ... </mirrors> ... <profiles> ... <profile> <id>jdk-1.8</id> <activation> <activeByDefault>true</activeByDefault> <jdk>1.8</jdk> </activation> <properties> <maven.compiler.source>1.8</maven.compiler.source> <maven.compiler.target>1.8</maven.compiler.target> <maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion> </properties> </profile> </profiles> |
refer to:
https://blog.csdn.net/baikunlong/article/details/113762152
https://www.bilibili.com/video/BV1kg4y1x7o6?p=49
https://mvnrepository.com