- wsl中共享 clash 参考:https://zhuanlan.zhihu.com/p/451198301 同时需要打开clash的allow lan,就搞定了。
2.wsl中git clone - rbenv install 3.2.2 报错了。c
Failing to install Ruby 2.7.7 on Ubuntu 20.04 due to OpenSSL 1.1.1t failing - Ask Ubuntu - 安装openssl还是会报错。但是错误变了 It seems your ruby installation is missing psych
安装psych后,ruby安装成功了 - gem install rails -v 7.1.1
6.bundle install 提示没有安装postgresql
7 按提示需要安装yum。最后没有用yum装,而是用apt安装,版本为14+
8 需要安装postgresql contributes 插件:pg_bigm btree_gist
9.apt-get 安装了postgresql 14+ service postgresql start 启动服务 - rails server, 因为没有正确的postgresql密码而失败
- rails中哪里设定pg密码了?database.yml
12:修改pg的密码 https://stackoverflow.com/questions/27107557/what-is-the-default-password-for-postgres
13: 执行rails db:migrate报错: could not open extension control file "/usr/share/postgresql/14/extension/pg_bigm.control": No such file or directory 没有安装pg_bigm插件的嘛。
根据 https://blog.csdn.net/weixin_45692576/article/details/129667199,来安装pg_bigm,文中所说官网已挂,所以从github下载了tar包。然后运行的时候记得加 sudo
sudo apt install postgis postgresql-14-postgis-3-scripts ==》尝试 没用
create extension postgis; ==》没用
14:安装postgresql_contribe
docker 搭建环境
https://driggl.com/blog/a/docker-setup-for-rails-development
https://dev.to/amree/introduction-to-ruby-on-rails-and-dockerfile-5a29
docker run -p 5050:80
-e "PGADMIN_DEFAULT_EMAIL=pgadmin@comcre.com"
-e "PGADMIN_DEFAULT_PASSWORD=Jira2022!"
-d dpage/pgadmin4
网友评论