1) Connecting to a Version Control System (VCS)






với authentication thì bạn chọn user/<Personal access tokens>
https://github.com/mrnim94/Accounting

sau khi connection successful thì bạn click “create”

2) VCS Root Connections and Open Authentication
Ở phần 1 chúng ta đã khai báo username/token github
Phần này chúng ta cần để tạo project dựa trên các repo trên github.
Mình ví dụ mình muốn tạo 1 project cho repo Accouting




Giờ ta vào github cấu hình









Invalid callback URL specified in GitHub OAuth application. Callback URL should be: http://192.168.101.34:8111/oauth/github/accessToken.html







3) Ways of organizing your projects in TeamCity
Projects tend to group build configurations
Build configurations include the instructions of building and deploying code
Root Project
Build and Package (Project)
Accounting
Fixed Asset
Deployments (Project)
Accounting
Root Project
Accounting (Project)
Build and package
Deploy to QA environment
Deploy to Production environment
Fixed Assets (Project)
Build and package
Deploy to QA environment
Deploy to Production environmen
4) Creating your first TeamCity project
Đầu tiên bạn cần tạo 1 project


Xong rồi click create

Giờ đến phần chúng ta tạo Build Configurations trong project




https://github.com/mrnim94/Accounting






5) Tools, Build Steps, Parameters and Templates!





Ở hiện tại bạn nhìn thôi nhé
Get environment/parameter hiden on teamcity
set -eux
auth="$(echo -n "$USER:$PASSWORD" | base64)"
echo "##teamcity[hide text='$auth']"
# Other code
echo cvbjNEVQ== | base64 --decode