我已经以这种方式安装了webpack:
npm install -g webpack
Run Code Online (Sandbox Code Playgroud)
现在要卸载它:
npm uninstall -g webpack
Run Code Online (Sandbox Code Playgroud)
再次检查,它没有被卸载:
webpack -v
3.1.0
Run Code Online (Sandbox Code Playgroud)
为什么?
而且,我用这种方式找不到webpack
:
npm list -g | grep webpack
Run Code Online (Sandbox Code Playgroud)
这也行不通:
npm uninstall -g webpack --save
Run Code Online (Sandbox Code Playgroud)
在包含以下内容的目录下运行之后package.json
:
npm uninstall webpack
npm WARN babel-loader@6.4.1 requires a peer of webpack@1 || 2 || ^2.1.0-beta || ^2.2.0-rc but none was installed.
npm WARN uglifyjs-webpack-plugin@0.3.1 requires a peer of uglify-js@^2.8.0 but none was installed.
npm WARN uglifyjs-webpack-plugin@0.3.1 requires a peer of webpack@^1.9 || ^2 || ^2.1.0-beta || ^2.2.0-rc …
Run Code Online (Sandbox Code Playgroud) 我安装minikube
在本地.
仪表板为192.168.99.100:30000
我用掌舵安装了詹金斯:
$ helm install stable/jenkins
Run Code Online (Sandbox Code Playgroud)
然后服务总是挂起:
$ kubectl get services --namespace=default -w wandering-buffoon-jenkins
NAME CLUSTER-IP EXTERNAL-IP PORT(S) AGE
wandering-buffoon-jenkins 10.0.0.153 <pending> 8080:31326/TCP,50000:31090/TCP 26m
Run Code Online (Sandbox Code Playgroud)
为什么?所以不能使用external-ip来访问它.
使用本指南在Vagrant集群上安装Kubernetes:
https://kubernetes.io/docs/getting-started-guides/kubeadm/
在(2/4) Initializing your master
,出现了一些错误:
[root@localhost ~]# kubeadm init
[kubeadm] WARNING: kubeadm is in beta, please do not use it for production clusters.
[init] Using Kubernetes version: v1.6.4
[init] Using Authorization mode: RBAC
[preflight] Running pre-flight checks
[preflight] Some fatal errors occurred:
/proc/sys/net/bridge/bridge-nf-call-iptables contents are not set to 1
[preflight] If you know what you are doing, you can skip pre-flight checks with `--skip-preflight-checks`
Run Code Online (Sandbox Code Playgroud)
我检查了/proc/sys/net/bridge/bridge-nf-call-iptables
文件内容,里面只有一个0
.
在(3/4) Installing a pod network
,我下载kube-flannel …
在 Rails 5 和 PostgreSQL 中。
我创建此文件是为了使用bigint
数据类型而不是integer
默认情况:
# config/initializers/bigint_primary_keys.rb
ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::NATIVE_DATABASE_TYPES[:primary_key] = 'bigserial primary key'
Run Code Online (Sandbox Code Playgroud)
因此,当运行 create 和 migrate 时,表 id 将被bigint
键入。
# posts table
id bigint not null
...
# users table
id bigint not null
...
Run Code Online (Sandbox Code Playgroud)
add_reference
但是在迁移中使用时:
class ChangeA < ActiveRecord::Migration[5]
def change
add_reference :posts, :users
end
end
Run Code Online (Sandbox Code Playgroud)
表posts
添加该字段:
# posts table
...
user_id integer
Run Code Online (Sandbox Code Playgroud)
和表id都是posts
type ,但是这个字段没有改变。users
bigint
有没有办法将数据类型设置为add_reference
方法?
剧本:
---
- name: Update repositories cache
apt: update_cache=yes
- name: Install build-essential
apt: name=build-essential state=present
- name: Disable SELinux
selinux: state=disabled
Run Code Online (Sandbox Code Playgroud)
结果:
TASK [common : Update repositories cache] ***************************************************************************************************************************************************************************************************
changed: [server]
TASK [common : Install build-essential] *****************************************************************************************************************************************************************************************************
ok: [server]
TASK [common : Disable SELinux] *************************************************************************************************************************************************************************************************************
fatal: [server]: FAILED! => {"changed": false, "failed": true, "msg": "libselinux-python required for this module"}
Run Code Online (Sandbox Code Playgroud)
我试图找到libselinux-python
但似乎不存在.当我尝试其他一些库时python-selinux
,无法在系统上安装.
kubernetes ×2
ansible ×1
docker ×1
jenkins ×1
minikube ×1
node.js ×1
npm ×1
postgresql ×1
python ×1
selinux ×1
ubuntu ×1
vagrant ×1
virtualbox ×1
webpack ×1