Docker ドキュメント 全文検索
Results of 1 - 1 of about 1 for widgets (0.001 sec.)
- 開発にコンテナを使う — Docker-docs-ja 24.0 ドキュメント 9414
- 言語別ガイド Python 開発にコンテナを使う 開発にコンテナを使う 事前準備 コンテナとしてイメージを実行 で、イメージ構築をし、それコンテナ化アプリケーションとして実行します。 概要 この章では、これまでのモジュールで構築したアプリケーション
...sk import Flask app = Flask ( __name__ ) @app . route ( '/' ) def hello_world (): return 'Hello, Docker!' @app . route ( '/widgets' ) def get_widgets (): mydb = mysql . connector . connect ( host = "mysqldb" , user = "root" , password = "p@ssw0rd1" , da...tabase = "inventory" ) cursor = mydb . cursor () cursor . execute ( "SELECT * FROM widgets" ) row_headers = [ x [ 0 ] for x in cursor . description ] #this will extract row headers results = cursor . fetchall () j...ot" , password = "p@ssw0rd1" , database = "inventory" ) cursor = mydb . cursor () cursor . execute ( "DROP TABLE IF EXISTS widgets" ) cursor . execute ( "CREATE TABLE widgets (name VARCHAR(255), description VARCHAR(255))" ) cursor . close () return 'ini... - https://man.mtool.work/docker/24.0/language/python/develop.html
PREV
1
NEXT