Skip to content

A 20tab standard project cookiecutter template.

License

Notifications You must be signed in to change notification settings

dvdria2/20tab-standard-project

 
 

Repository files navigation

20tab standard project

Code style: black Build Status

A 20tab standard project cookiecutter template.

📝 Conventions

In the following instructions:

  • projects is your actual projects directory
  • My Project Name is your chosen project name

🧩 Requirements

🍪 Cookiecutter

Cookiecutter must be installed in order to create and initialize the project structure.

$ python3 -m pip install cookiecutter

🔀 Git

Install the git command-line, if the GitLab integration is needed.

  • 🍏 macOS

    $ brew install git
  • 🐧 GNU/Linux

    $ sudo apt install git

🦝 GitLab

📦 Install

Install the python-gitlab package, if the GitLab integration is needed.

$ python3 -m pip install python-gitlab

✅ Token

A GitLab user account is required by the setup procedure to create the repositories, and by Kubernetes to pull the images from the Docker registry.

Make sure you have a local SSH key and have it associated with your GitLab account in the "SSH Keys" section in the settings.

Put the GitLab Access Token of the chosen user in an environment variable (e.g. export it in the command line or add it to the bash config).

$ export GITLAB_PRIVATE_TOKEN={{gitlab_private_token}}

Note: the access token can be generated from the GitLab settings "Access Tokens" section. Make sure to give it full permission. Beware that GitLab only shows the token right after creation, and hides it thereafter.

🚀️ Quickstart

Change directory and create a new project as in this example:

$ cd ~/projects/
$ cookiecutter https://github.com/20tab/20tab-standard-project
project_name: My Project Name
project_slug [myprojectname]:
domain_url [myprojectname.com]:
Select which_frontend:
1 - None
2 - React (TypeScript)
3 - React
Choose from 1, 2, 3 [1]:
Select use_gitlab:
1 - Yes
2 - No
Choose from 1, 2 [1]:
Select use_media:
1 - Yes
2 - No
Choose from 1, 2 [1]:
Generated '.env' file.
Generated '/requirements/common.txt' file.
Generated '/requirements/dev.txt' file.
Generated '/requirements/prod.txt' file.
Generated '/requirements/tests.txt' file.
Generated '/static' directory.
Choose the gitlab group path slug [myprojectname]:
Insert a comma separated list of usernames to set as group owners:
Insert a comma separated list of usernames to set as group mantainers:

🚚 Setup

To configure the Kubernetes cluster now, read the SETUP documentation.

About

A 20tab standard project cookiecutter template.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 92.3%
  • Shell 3.7%
  • Makefile 3.1%
  • Dockerfile 0.9%