Giter Site home page Giter Site logo

twtrubiks / docker-tutorial Goto Github PK

View Code? Open in Web Editor NEW
1.6K 1.6K 290.0 133 KB

Docker 基本教學 - 從無到有 Docker-Beginners-Guide 教你用 Docker 建立 Django + PostgreSQL 📝

License: MIT License

Python 94.71% Dockerfile 2.99% Shell 2.30%
django django-rest-framework docker postgresql tutorial

docker-tutorial's Introduction

Hey there, I'm twtrubiks 👋

I'm a Developer !!

  • 🔭 I'm a backend developer
  • 🌱 I like to learn new knowledge, especially python and linux
  • 👯 Coding is my live
  • 🥅 Hope to contribute to society through coding
  • ⚡ What I write is not a code, but a dream
  • 📺 I make development and tech tutorials on YouTube
  • 🔭 My CV - https://www.cakeresume.com/blue555236sa56

🙋‍♂️ Connect with me:

twtrubiks | YouTube twtrubiks | Facebook twtrubiks | LinkedIn twtrubiks | Gmail


👨‍💻 Languages and Tools:

python odoo visualstudio linux docker nginx django flask git jenkins kubernetes postgresql postman



📺 Latest YouTube Videos

odoo 16 手把手教學 - json fields - 改善效能
Sep 24, 2023
postgresql 教學 - json jonsb
Sep 10, 2023
Odoo16 mobile scan 手機掃描電子發票自動建立憑證
Aug 27, 2023
odoo 16 手把手教學 - fake Binary fields(改善效能)
Aug 13, 2023
海象運算符 PEP 572 – Assignment Expressions - python3
Aug 6, 2023

➡️ more videos...


📈 Github Stats

twtrubiks's GitHub Stats

docker-tutorial's People

Contributors

twtrubiks avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

docker-tutorial's Issues

README improvement

Hi @twtrubiks !

我看完了你的影片,講解很清楚,有些 feedback!

  1. 雖然大概懂你的意思,不過 docker-compose 那邊有提到,一個 web service 通常不會只有 server,還會有 database、redis 等等,是不是可以加入『這些 services 分別跑在不同的 container 上,所以可以用 docker-compose 來統一管理這些 container』呢?

  2. 好像沒有介紹到最近也很火的 Kubernetes (k8s),我發覺這 k8s 和 docker-compose 東西好像很像,也許可以帶個解說?

Veck

README improvement [mistaken opening]

雖然大概懂你的意思,不過 docker-compose 那邊有提到,一個 web service 通常不會只有 server,還會有 database、redis 等等,是不是可以加入『這些 services 分別跑在不同的 container 上,所以可以用 docker-compose 來統一管理這些 container』呢?

Can not access the webpage after deployed on to the server

Hello, thanks your this great tutorial, helped me a lot, but after I deployed this project onto my server, it report the following problems:

image

When I deployed my own project, when I access the page, the server displays following outputs:

image

Can you help give me some instructions, thanks.

If you are happy to help solve this problem, I can give you my access to my server, my email is jun.ren.nz at gmail.com

I will appreciate all your help.

Some useful tips

Remove dangling images.

docker image prune

Remove all unused images and dangling images.

docker image prune -a

Remove all stopped containers.

docker container prune

多项目的问题

你好,在生产环境中,我已经构建了第一个项目,docker-compose文件里含有nginx(映射到433),django,db,并成功运行。
我的问题是:我的第二个django项目的docker-compose应该怎么写呢?
我应该如何连接到第一个项目创建的nginx?

執行至docker-compose up時出錯

錯誤訊息:web_1 | python: can't open file 'manage.py': [Errno 2] No such file or directory
檔案配置:
image
請問這是什麼地方出錯呢

無法順利實作教學內容

大大你好
之前都有在關注你發表有關python的教學內容

最近這兩天在看您發表有關docker的教學
但對內容的編排上有小小的疑惑

之前就有觀看大大其他的教學影片
如python的爬蟲 跟 Django教學
實作都可以順利的完成

但在這一篇docker從無到有 的教學
我就無法順利閱讀下去&實作

文章開頭先介紹docker &安裝
大大是安裝在windows10上面

我是裝在Google Cloud Platform上面

docker裝好後,大大有介紹用 Kitematic 這個管理工具
我是安裝 大大在文章後段提到的 portainer
我也裝在GCP上面(GCP管理頁面開好port)也順利看到portainer 的畫面跟登入操作

文章內容到了 "指令介紹"

建立image
docker create -it --name busybox busybox

文章內容從這邊開始我就無法實作下去...(無法理解內容的編排)

我以為從建立第一個 image 之後
文章內容應該導向
"怎麼從無到有的在Docker的環境裡去建立 Django + PostgreSQL"

實際上
建立busybox 這個image後,就開始說明一些docker的指令用法
文章的標題也是"指令介紹"

看完指令介紹後,接著介紹 Volume 、 network、docker-compose、Docker Registry

最後是 用 "Docker 實戰 Django 以及 Postgre"
看到這邊我無法將這邊的內容跟文章前段去做連接

我以為是要先去pull Django 、Postgre之類的
然後去做設定...

整篇文章看完,我是無法從無到有的用docker建立一個django環境
也許是我個人的問題
感謝大大花時間那麼多時間寫教學文章!!
我會繼續收看的 XD

ps:
1.
關於docker 我也有一點不能理解
docker本身沒有含os
那為什麼 從Docker下載 Nginx
在沒有pull其他os的情況下~可以run Nginx 這個image...
是靠原本主機的OS嗎?

因為是第一次接觸docker
我以為跟用VM差不多
先有OS + LAMP + Django 之類的
只不過這些都可以拆開成單獨的image 後組合起來

readme問題

您好,請問介紹portainer那邊是不是有一張死圖阿? 疑惑很久:flushed:

AssertionError at /api-auth/login/ database connection isn't set to UTC

您好,我執行您的教學至連上網站登入密碼時那邊出錯
問題解決方式 目前參考網路上主要有兩種做法 一種是將psycopg2 downgrade至2.8.6
因此我直接在更改requirements.txt為
image
另一種則是在setting裡的 USE_TZ = True更改为USE_TZ = False
image

兩種改動都是更改後重新compose up不過錯誤一樣出現
請問此問題如何解決

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.