You should skip setting up infrastructure in the following situations:
- You want to run your projects only locally for now.
- Your organization is already using Taito CLI. In such case you should use the existing infrastructure, and ask for taito configuration settings from your colleagues and copy-paste the settings to your
~/.taito/taito-config.shfile.- You already have an existing infrastructure, but no Taito CLI configurations for it. In such case, you should execute the following steps, but skip the step 2.
You can create a new zone with the following steps:
Create a new zone configuration based on one of the infrastructure templates. For example:
cd devops # New or existing git repository for infrastructure configurations
taito zone create gcp
cd my-zone
EDIT taito-config.sh
EDIT *.yamlApply infrastructure configuration by running the following command, and follow instructions. This creates you a zone; typically consisting of a Kubernetes cluster, database clusters, object storage buckets, container registry, virtual private network, and some settings related to logging, monitoring, and IAM.
taito auth
taito zone applyTIP: If you encounter an error while running Terrafom, just try to run
taito zone applyagain.
View the created resources on your cloud provider dashboard:
taito open dashboardRECOMMENDATION: Use the dashboard for viewing only. If you need to make changes to the infrastructure, make changes to the zone configuration files, and run
taito zone applyto apply the changes. This way you can keep all your infrastructure configurations in version history (infrastructure as code).
Commit your zone configuration files to some git repository.
RECOMMENDATION: Create one git repository for all of your zones, and give write permission for DevOps personnel only.
Display project template settings with taito project settings and copy-paste the settings to your ~/.taito/taito-config.sh file. You'll need these settings when you create a new project for the zone.
taito -q project settings >> ~/.taito/taito-config.shTIP: Your default configuration is located in
~/.taito/taito-config.sh. You can also have additional configurations, e.g.~/.taito/taito-config-company-x.sh.
Create a new project based on one of the project templates. For example:
taito project create full-stack-template
cd acme-myprojectTIP: You can choose some other than default configuration with
-o, for example:taito -o company-x project create full-stack-template.
Clean start the local development environment with the following command. This typically initializes your local secrets, installs some libraries, builds and starts containers, and initializes your database with tables and some data. Secret default values are typically copied from dev environment, if available.
taito developIn case of trouble, run
taito trouble. Sometimestaito developmight fail and hopefullytaito troublehelps.
Open application web UI on your browser:
taito open clientConnect to the database:
taito db connectIf you skipped the setting up infrastructure part before, now is the right time to create the zone, and to update your project with the correct settings by running
taito project upgrade.
View organization specific conventions, and follow instructions:
taito open conventionsApply project wide settings:
taito project applyMake sure your authentication is in effect:
taito auth:devCreate dev environment with the following command. This typically creates a database and some cloud resources (e.g. storage buckets), initializes secrets, and sets up the CI/CD pipeline. Note that if you are not the one who created the infrastructure, you might not have enough permissions to create new environments in it, unless you were given such permissions separately.
taito env apply:devTrigger the first CI/CD deployment by committing and pushing changes to dev branch (you can do this with git tools also). Note that you should write your commit message according to Conventional Commits:
taito stage # Or just: git add .
taito commit # Or just: git commit -m 'chore: configuration'
taito push # Or just: git pushShow build status on browser:
taito open builds:devShow status of dev environment:
taito status:devOpen application web UI running on dev environment:
taito open client:devShow credentials for signing in (basic auth):
taito info:devTail logs of server container running on dev environment:
taito logs:server:devInitialize dev environment database with some development data:
taito init:devConnect to the dev environment database:
taito db connect:devMake sure your authentication is in effect:
taito auth:prodCreate production environment:
taito env apply:prodMerge changes between environments: dev -> ... -> prod (you can do this with git tools also, but always use fast-forward when merging between environment branches):
taito env merge:dev prodShow production environment build status on browser:
taito open builds:prodOpen application web UI running on prod environment:
taito open client:prodShow release notes for the first production release you just made:
taito open releasesSemantic-release library requires version control personal access token (GitHub/GitLab/BitBucket) for accessing the version control API. Release notes will be generated only if you configured the token during the zone creation, or you configured VC_TOKEN environment variable for your CI/CD pipeline.
Run taito -h to show more taito commands that you can use, or see the help.txt. Check also the DEVELOPMENT.md file located at your project root folder.
Next: 4. Usage