0Pricing
Django Academy · レッスン

django-admin startprojectを理解する

プロジェクトの骨組みを生成し、各ファイルを読み解きます

「django-admin startprojectを理解する」はCoddyKit上の無料Django Academyレッスンです。 これはレッスン3/4です。 下記で完全なレッスンを無料で読むことができます。その後、ブラウザ内の組み込みコードエディタと24時間対応のAIチューターでハンズオン演習できます。 これはDjango Academy学習パスの一部であり、ウェブとCoddyKitアプリ全体で進捗が同期されます。 Django Academyコースには全4レッスンが含まれています。

このレッスンの一部はまだ翻訳されておらず、英語で表示されています。

Scaffold a Project

Django can generate a working project skeleton for you. The startproject command builds the folders and files you need to begin. 🏗️

django-admin startproject mysite

What Got Created

You now have an outer mysite folder holding manage.py plus an inner config package. That structure is the backbone of every Django app.

Meet manage.py

The manage.py file is your command center. You run servers, migrations, and admin tasks through it for the rest of the project.

The Inner Config Package

Inside sits a package named after your project. This config package holds the settings that wire everything together.

settings.py

The settings.py file controls your whole project: installed apps, the database, templates, and more, all in one Python module.

urls.py

The urls.py file maps incoming web addresses to your code. It is the front door that decides which view answers each request.

wsgi.py

The wsgi.py file is the entry point production servers use to talk to your app over the classic synchronous interface.

asgi.py

The asgi.py file is the modern async entry point. It supports websockets and long-lived connections beyond plain HTTP.

The Empty init File

An __init__.py marks the config folder as a Python package, so its modules can be imported across the project.

Avoid Nested Folder Confusion

Add a trailing dot to put config files in the current folder. This dot skips the extra wrapping directory many beginners trip over.

django-admin startproject mysite .

Name It Wisely

Pick a clear project name, since it becomes a Python package. Avoid names like django or test that clash with existing modules.

Quick Check

Let's check the generated files.

Recap

You scaffolded a project and toured its files: manage.py, settings, urls, wsgi, and asgi. The skeleton is ready to grow. 🎉

よくある質問

「django-admin startprojectを理解する」レッスンは無料ですか?

はい。「django-admin startprojectを理解する」の完全なテキストはこのウェブで無料で読めます。インタラクティブに演習し(組み込みコードエディタと24時間対応のAIチューター)、Django Academyコースの残りをアンロックするには、CoddyKit PROにアップグレードしてください。 Django Academyコースには全4レッスンが含まれています。

「django-admin startprojectを理解する」で何を学びますか?

プロジェクトの骨組みを生成し、各ファイルを読み解きます ブラウザで直接実行するハンズオンコードでDjango Academyを演習し、24時間対応のAIチューターがレッスンを進める中での質問に答えます。

Django Academyを始めるのに経験は必要ですか?

事前経験は必要ありません。CoddyKitのDjango Academyは初級者から上級者向けに構成されているため、ここから始めるか最初から始めて、自分のペースで進むことができます。 これはレッスン3/4です。

「django-admin startprojectを理解する」レッスンにはどのくらい時間がかかりますか?

ほとんどのCoddyKitレッスンは約5~10分かかります。各レッスンはコンパクトでインタラクティブなので、着実に進歩し、ウェブとアプリ全体で正確に前回の場所から再開できます。

このDjango Academyレッスンでコードを書いて実行できますか?

はい。すべてのDjango Academyレッスンに組み込みコードエディタが含まれているため、ブラウザでリアルコードを書いて実行し、即座のAIフィードバックを取得できます。ローカル設定は不要です。

このコースのすべてのレッスン

  1. venvによる仮想環境
  2. pip install djangoとバージョン固定
  3. django-admin startprojectを理解する
  4. runserverで開発サーバーを起動する
← Django Academyに戻る