thumbnail
Exec commands on kubernetes pods with root access
from--https://stackoverflow.com/questions/42793382/exec-commands-on-kubernetes-pods-with-root-access   Ask Question Asked 6 years, 5 months ago Modified 1 month ago Viewed 262k times 131 I have one pod running with name 'jenkins-app-2843651954-4zqdp'. I want to install few softwares temporarily on this pod. How can I do this? I am trying this- kubectl exec -it jenkins…
c++封装so库,供安卓android调用
from--https://www.361shipin.com/blog/1553848763561279488#CCJNIjavaJNIso_220 文章目录 一、概述 二、用C/C++开发出Linux的so库 1.开发分析: 2.开发准备: 三、在C/C++代码里加入JNI,支持java通过JNI调用so库 1、JNI 是Java Native Interface的缩写,中文译为“Java本地调用”。通常使用JNI技术可以做到以下两点: 2、当然任何事物都有两面性,JNI也不例外,使用JNI主要缺点有以下两点: 3、Android主要使用java开发,但Android可以通过java的JNI调用C/C++编写的so库,实现Android对C/C++的支持。接下来我们在前面so的基础上加入JNI,以支持java通过JNI调用so的方法。 …
Bash脚本判别使用者的身份
from--https://segmentfault.com/a/1190000018029866 经常要在bash脚本里面或者直接对脚本本身加上sudo运行命令,但是这引发了一系列的问题。 比如用sudo的时候,脚本里的~或$HOME指代用户文件夹的这个变量,到底是应该指向我真正的用户文件夹如/home/pi呢,还是指向了超级管理员的用户文件夹/root/呢? 实际上它指向了/root/文件夹,这是我们绝对不想要的。但是很多命令如安装个程序,都不得不用sudo,那怎么办? 首先要说下经验:命令行的权限执行,从表现上来看,可以分为以下5种情况: admin-manual: 普通用户手敲命令 sudo-manual: 手敲命令加sudo admin-bash: 以普通用户执行bash脚本 sudo-bash: 以sudo执行bash脚本 ro…
Cannot find module ‘ts-node/register’
from--https://www.e-learn.cn/topic/3406167 由 半世苍凉 提交于 2020-02-20 06:22:29 问题 I want to use mocha to test my TypeScript/Angular2 project. I tried to use ts-node as described here: npm install -g ts-node but when running mocha --require ts-node/register -t 10000 ./*/.unit.ts I get an error Cannot find module 'ts-node/register' What am I missing here? 回答1: Since the answer th…
Centos的openresty安装记录
from--https://www.kvm.la/1043.html 以下是自用的openresty编译归纳 yum安装常用包 yum -y update yum -y install epel-release -y yum install lua-devel luajit git dos2unix mercurial -y yum -y --skip-broken install gcc vim-enhanced gcc-c++ libtool-libs libtool autoconf subversion zip unzip wget crontabs iptables file bison patch mlocate flex diffutils automake imake make cmake cpp unix2dos merc…
chromium gn parameter list
from--https://blog.csdn.net/LostSpeed/article/details/84984020 前言 查资料时,看到如何看gn都提供什么参数列表了. 这样,编译chromium工程时,可以编译的更精细。 实验 可以将参数写到 Z:\chromium\src\out\my_x86_d\args.gn 中 编译时,执行 gn --ide=vs args out\my_x86_d e.g. # @file Z:\chromium\src\out\my_x86_d\args.gn # @brief build chromium x86 release version # @ref https://www.chromium.org/developers/gn-build-configuration # https://b…
thumbnail
CONFIGURING MULTIPLE NETWORKED OR USB APC UPS DEVICES
from--https://crossan007.dev/blog/linux/configuring-multiple-networked-apc-ups-devices/ DECEMBER 19, 2019 CROSSAN007 LEAVE A COMMENT As any proper IT-nerd would agree, UPS devices are critical pieces of equipment not only in the data center, but also at home. However, most home users are not in a position to acquire a massive 10+ kilovolt-amp UPS capable of protecting all …