From 8416cf8c08e9fa2cce0ad7b61d3a029c67ed23b7 Mon Sep 17 00:00:00 2001 From: Morteza Tavanarad Date: Tue, 3 Mar 2020 17:15:30 +0800 Subject: [PATCH 01/46] Preparing V2.5.1 (#1345) * make digits contract's barrier to be integer * New translations en.json (Italian) * New translations en.json (Italian) * update shelljs * fix buy * use buy instead of portfolio to fix chart hang when tick is 1 * remove subscribing to buy as it is unnecessary * fix missing profit/loss and sell_price in transaction details (#1323) * fix average becoming NaN in Asian trade (#1324) * update lodash (#1325) * Fix sending not shown in authorize as token (#1326) * Fix sending not shown in authorize as token * remove saved token after logout * Changed app icon * Morteza/new_app_icon (#1327) * Preparing version 2.4.5 (#1319) * make digits contract's barrier to be integer * New translations en.json (Italian) * New translations en.json (Italian) * V2.4.5 * Changed app icon * New translations en.json (Italian) * Fix self exclusion time and date fields * refactor * fixes to self exclusion * fix eslint * not validate exclude until when user has set it already * fix exclude until error and make it show the correct time user selected * Change 30 to 50 max chars for first name and last name * New translations en.json (Vietnamese) * New translations en.json (Vietnamese) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Traditional) * New translations en.json (French) * New translations en.json (German) * New translations en.json (Indonesian) * New translations en.json (Italian) * New translations en.json (Polish) * New translations en.json (Portuguese) * New translations en.json (Russian) * New translations en.json (Spanish) * New translations en.json (Thai) * New translations en.json (Acholi) * New translations en.json (Indonesian) * New translations en.json (Indonesian) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Traditional) * New translations en.json (Spanish) * New translations en.json (Spanish) * New translations en.json (Polish) * New translations en.json (Polish) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Portuguese) * New translations en.json (Vietnamese) * New translations en.json (Russian) * New translations en.json (Thai) * New translations en.json (French) * New translations en.json (French) * New Crowdin translations (#1335) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * Dev (#1336) * Preparing version 2.4.5 (#1319) * make digits contract's barrier to be integer * New translations en.json (Italian) * New translations en.json (Italian) * V2.4.5 * Changed app icon * Preparing V2.4.6 (#1328) * make digits contract's barrier to be integer * New translations en.json (Italian) * New translations en.json (Italian) * update shelljs * fix buy * use buy instead of portfolio to fix chart hang when tick is 1 * remove subscribing to buy as it is unnecessary * fix missing profit/loss and sell_price in transaction details (#1323) * fix average becoming NaN in Asian trade (#1324) * update lodash (#1325) * Fix sending not shown in authorize as token (#1326) * Fix sending not shown in authorize as token * remove saved token after logout * Morteza/new_app_icon (#1327) * Preparing version 2.4.5 (#1319) * make digits contract's barrier to be integer * New translations en.json (Italian) * New translations en.json (Italian) * V2.4.5 * Changed app icon * V2.4.6 * Support synthetic_index * Add sythetic_indices to translation file * Fixed the issue of wrong contract response. * Fixed the issue adding cert with new version of shelljs * New Crowdin translations (#1338) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Traditional) * New translations en.json (French) * New translations en.json (Indonesian) * New translations en.json (Italian) * New translations en.json (Polish) * New translations en.json (Portuguese) * New translations en.json (Russian) * New translations en.json (Spanish) * New translations en.json (Thai) * New translations en.json (Vietnamese) * New translations en.json (Acholi) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Traditional) * New translations en.json (Spanish) * New translations en.json (Polish) * New translations en.json (Indonesian) * New translations en.json (Russian) * New translations en.json (Vietnamese) * Added meta referrer tag * New Crowdin translations (#1341) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Italian) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Traditional) * New translations en.json (French) * New translations en.json (Indonesian) * New translations en.json (Italian) * New translations en.json (Polish) * New translations en.json (Portuguese) * New translations en.json (Russian) * New translations en.json (Spanish) * New translations en.json (Thai) * New translations en.json (Vietnamese) * New translations en.json (Acholi) * New translations en.json (Chinese Simplified) * New translations en.json (Chinese Traditional) * New translations en.json (Spanish) * New translations en.json (Polish) * New translations en.json (Indonesian) * New translations en.json (Russian) * New translations en.json (Vietnamese) * New translations en.json (Italian) * New translations en.json (French) * New translations en.json (Portuguese) * New translations en.json (Thai) * New translations en.json (Vietnamese) * New translations en.json (Vietnamese) * New translations en.json (Vietnamese) Co-authored-by: Morteza Tavanarad Co-authored-by: Nazanin Reihani <6875585+nazaninreihani@users.noreply.github.com> Co-authored-by: Ashkan --- www/i18n/fr.json | 4 ++-- www/i18n/it.json | 4 ++-- www/i18n/pt.json | 4 ++-- www/i18n/th.json | 4 ++-- www/i18n/vi.json | 50 ++++++++++++++++++++++++------------------------ www/index.html | 3 ++- 6 files changed, 35 insertions(+), 34 deletions(-) diff --git a/www/i18n/fr.json b/www/i18n/fr.json index c88bd06642..de983eb1e1 100644 --- a/www/i18n/fr.json +++ b/www/i18n/fr.json @@ -507,8 +507,8 @@ "otc_stocks": "Actions OTC", "volidx": "Volidx", "volatility_indices": "Indices de volatilité", - "synthetic_indices": "Synthetic Indices", - "synthetic_index": "Synthetic Indices", + "synthetic_indices": "Indices Synthétiques", + "synthetic_index": "Indices Synthétiques", "subject_to_change": "Les limites indiquées peuvent être modifiées sans préavis.", "trading_limits": "Limites de trading", "withdrawal_limits": "Limites de retrait", diff --git a/www/i18n/it.json b/www/i18n/it.json index b72b409208..e2b0d7d1a2 100644 --- a/www/i18n/it.json +++ b/www/i18n/it.json @@ -507,8 +507,8 @@ "otc_stocks": "Azioni OTC", "volidx": "Volidx", "volatility_indices": "Indici di volatilità", - "synthetic_indices": "Synthetic Indices", - "synthetic_index": "Synthetic Indices", + "synthetic_indices": "Indici sintetici", + "synthetic_index": "Indici sintetici", "subject_to_change": "I limiti fissi sono soggetti a modifica senza alcun preavviso.", "trading_limits": "Limiti del trading", "withdrawal_limits": "Limiti per i prelievi", diff --git a/www/i18n/pt.json b/www/i18n/pt.json index f9a7440803..9571684fb5 100644 --- a/www/i18n/pt.json +++ b/www/i18n/pt.json @@ -507,8 +507,8 @@ "otc_stocks": "Ações OTC", "volidx": "Volidx", "volatility_indices": "Índices Volatility", - "synthetic_indices": "Synthetic Indices", - "synthetic_index": "Synthetic Indices", + "synthetic_indices": "Índices Sintéticos", + "synthetic_index": "Índices Sintéticos", "subject_to_change": "Os limites mencionados estão sujeitos a alterações sem aviso prévio.", "trading_limits": "Limites de negociação", "withdrawal_limits": "Limites de retirada", diff --git a/www/i18n/th.json b/www/i18n/th.json index c05e9db543..12ece9acb4 100644 --- a/www/i18n/th.json +++ b/www/i18n/th.json @@ -507,8 +507,8 @@ "otc_stocks": "หลักทรัพย์ OTC", "volidx": "Volidx", "volatility_indices": "ดัชนีความผันผวน", - "synthetic_indices": "Synthetic Indices", - "synthetic_index": "Synthetic Indices", + "synthetic_indices": "ดัชนีสังเคราะห์", + "synthetic_index": "ดัชนีสังเคราะห์", "subject_to_change": "วงเงินที่ได้รับที่ระบุไว้อาจจะมีการเปลี่ยนแปลงโดยไม่บอกกล่าวให้ทราบล่วงหน้า", "trading_limits": "วงเงินในการซื้อขาย", "withdrawal_limits": "วงเงินในการถอน", diff --git a/www/i18n/vi.json b/www/i18n/vi.json index 9e8970961c..b9ef81afe7 100644 --- a/www/i18n/vi.json +++ b/www/i18n/vi.json @@ -6,7 +6,7 @@ "get_token": "Làm thế nào để nhận mã Token?", "signin_with_binary_com": "Đăng nhập", "next": "Tiếp theo", - "regulatory_information": "Thông tin điều chỉnh" + "regulatory_information": "Thông Tin Quy Định" }, "alert": { "error": "Lỗi!", @@ -15,7 +15,7 @@ "not_auth": "Xin lỗi, chúng tôi không thể xác thực bạn.", "not_unique": "Bạn đã thêm tài khoản này.", "contract_error": "Hợp đồng không khả dụng, vui lòng thử lại.", - "no_tick": "Vui lòng lựa chọn một thị trường cơ bản khác, Thị trường cơ bản mà bạn chọn không hỗ trợ khoảng thời gian là giây.", + "no_tick": "Vui lòng lựa chọn một thị trường cơ bản khác, Thị trường cơ bản mà bạn chọn không hỗ trợ khoảng thời gian là tick.", "remove_token_title": "Xóa bỏ mã Token", "remove_token_content": "Bạn có chắc muốn xóa mã token này?", "remove_all_tokens_title": "Thoát", @@ -57,59 +57,59 @@ "select_underlying": "Chọn mục được gạch chân", "select_tradetype": "Chọn loại giao dịch", "select_tick": "Chọn Tick", - "select_digit": "Chọn Digit", + "select_digit": "Chọn Chữ số", "selected_tick": "Tick đã chọn", - "last_digit": "Số cuối" + "last_digit": "\bChữ số cuối" }, "trade": { - "payout": "Thanh toán", + "payout": "Mức chi trả", "stake": "Cổ phần", "buy": "Mua", "net_profit": "Lợi nhuận ròng", - "potential_payout": "Khả năng thanh toán", + "potential_payout": "Mức chi trả tiềm năng", "total_cost": "Tổng chi phí", "potential_profit": "Lợi Nhuận Tiềm Năng", - "back": "Quay lại thương mại", + "back": "Quay lại Giao dịch", "loss": "Thua lỗ", - "win": "Hợp đồng này đã thắng", - "lose": "Hợp đồng này đã thất bại", + "win": "Thắng", + "lose": "Thua thầu", "transaction_id": "Tham chiếu giao dịch", "buy_again": "Mua lại", "sell": "Bán", "barrier": "Rào cản bù đắp", - "return": "Quay trở lại", + "return": "Quay lại", "tick": "tick" }, "app": { "exit_title": "Thoát", "exit_confirmation": "Bạn có chắc chắn muốn thoát?", - "connection_error": "Không có không kết nối internet!", + "connection_error": "Không có kết nối internet!", "ssl_cert_failed": "Kết nối của bạn không phải là riêng tư!", "sign_out": "Đăng xuất" }, "reality-check": { - "title": "Kiểm lại thực tế", - "about": "Giao dịch các tùy chọn có thể trở thành một cơn nghiện thực sự, như bất kỳ hoạt động nào khác bị đẩy đến giới hạn của nó. Để tránh rủi ro của một cơn nghiện nhu vậy, chúng tôi cung cấp một phương thức kiểm duyệt thực tế cung cấp cho bạn một bản tổng quát những giao dịch và tài khoản của bạn một cách thường xuyên.", + "title": "Kiểm duyệt Thực tế", + "about": "Giao dịch các tùy chọn có thể trở thành một cơn nghiện thực sự, như bất kỳ hoạt động nào khác bị đẩy đến giới hạn của nó. Để tránh rủi ro của một cơn nghiện như vậy, chúng tôi đưa ra phương thức kiểm duyệt thực tế để cung cấp cho bạn một bản tổng quát những giao dịch và tài khoản của bạn một cách thường xuyên.", "login_time": "Thời gian đăng nhập:", "current_time": "Thời gian hiện tại:", - "session_duration": "Thời hạn phiên:", + "session_duration": "Thời lượng phiên:", "interval_question": "Xin vui lòng ghi rõ khoảng thời gian kiểm duyệt thực tế phù hợp với bạn trong vài phút:", "loginid": "ID Đăng nhập", - "currency": "Đơn vị tiền tệ", + "currency": "Tiền tệ", "buy_amount": "Doanh số", "profit_loss": "Lãi/Lỗ", - "buy_count": "Hợp đồng đã được mua", - "sell_count": "Hợp đồng đã được bán", - "open_contract_count": "Hợp đồng Mở", + "buy_count": "Gói thầu đã mua", + "sell_count": "Gói thầu đã bán", + "open_contract_count": "Gói thầu Mở", "potential_profit": "Lợi nhuận tiềm năng", - "interval": "Khoảng thời gian kiểm lại thực tế trong vài phút", - "continue": "Tiếp tục giao dịch", + "interval": "Khoảng Thời gian Kiểm duyệt Thực tế trong Vài Phút", + "continue": "Tiếp tục Giao dịch", "logout": "Đăng xuất", "days": "ngày", "hours": "giờ", "minutes": "phút", - "interval_error": "Vui lòng nhập một con số trong khoảng từ 10 đến 60.", - "view_statement": "Xem tuyên bố", + "interval_error": "Vui lòng nhập một số trong khoảng từ 10 đến 60.", + "view_statement": "Xem Sao Kê", "integer_error": "Khoản thời gian nên là số nguyên." }, "new-virtual-account": { @@ -166,13 +166,13 @@ "continue": "Tiếp tục", "cancel": "Hủy bỏ", "not_pep_verify": "Tôi thừa nhận rằng tôi không phải là một cá nhân có ảnh hưởng chính trị (PEP)", - "pep_info": "Một PEP là một cá nhân mà đã hoặc đang được ủy thác với một chức vụ nổi trội trước công chúng. Thân thế địa vị này bao gồm cả người thân trong gia đình và các đồng đảng liên quan của PEP.", + "pep_info": "Một PEP là một cá nhân mà đã hoặc đang được ủy thác với một chức vụ nổi trội trước công chúng. Thân thế địa vị này bao gồm cả người thân trong gia đình và các bên liên quan của PEP.", "forex_trading_experience": "Kinh nghiệm giao dịch ngoại hối", "forex_trading_frequency": "Tần suất giao dịch ngoại hối", "binary_options_trading_experience": "Kinh nghiệm giao dịch Quyền Chọn Nhị Phân", - "binary_options_trading_frequency": "Tần xuất giao dịch Quyền Chọn Nhị Phân", + "binary_options_trading_frequency": "Tần suất giao dịch Quyền Chọn Nhị Phân", "cfd_trading_experience": "Kinh nghiệm giao dịch CFD", - "cfd_trading_frequency": "Tần xuất giao dịch CFD", + "cfd_trading_frequency": "Tần suất giao dịch CFD", "other_instruments_trading_experience": "Kinh nghiệm giao dịch trong các công cụ tài chính khác", "other_instruments_trading_frequency": "Tần suất giao dịch trong các công cụ tài chính khác", "employment_industry": "Ngành nghề tuyển dụng", diff --git a/www/index.html b/www/index.html index cfcd3d9116..b83d98d056 100644 --- a/www/index.html +++ b/www/index.html @@ -4,7 +4,8 @@ - + + From 9ee7774b3a618e30829210bf0f0918bd445acbed Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 17:27:04 +0800 Subject: [PATCH 02/46] add circleci pipeline --- .circleci/config.yml | 144 +++++++++++++++++++++++++++++++++++++++++++ .dockerignore | 2 + Dockerfile | 3 + default.conf | 22 +++++++ 4 files changed, 171 insertions(+) create mode 100644 .circleci/config.yml create mode 100644 .dockerignore create mode 100644 Dockerfile create mode 100644 default.conf diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 0000000000..913fb7f55f --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,144 @@ +version: 2.1 +orbs: + k8s: circleci/kubernetes@0.7.0 + s3: circleci/aws-s3@1.0.13 +commands: + git_checkout_from_cache: + description: "Git checkout and save cache" + steps: + - restore_cache: + name: Git restore cache + keys: + - source-v1-{{ .Branch }}-{{ .Revision }} + - source-v1-{{ .Branch }}- + - source-v1- + - run: + name: Fetch git tags + command: | + mkdir -p ~/.ssh + echo 'github.com ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ== ' >> ~/.ssh/known_hosts + # Fetch tags if git cache is present + if [ -e /home/circleci/project/.git ] + then + git fetch origin --tags + fi + - checkout + - run: + name: Compress git objects + command: git gc + - save_cache: + name: Git save cache + key: source-v1-{{ .Branch }}-{{ .Revision }} + paths: + - ".git" + npm_install: + description: "Install npm modules" + steps: + - restore_cache: + name: Restore npm cache + keys: + - npm-v1-{{ checksum "package.json" }} + - npm-v1- + - run: + name: Install npm modules + command: yarn + - save_cache: + name: Save NPM cache + key: npm-v1-{{ checksum "package.json" }} + paths: + - "node_modules" + build: + description: "Build" + steps: + - run: + name: "yarn build" + command: node_modules/gulp/bin/gulp.js build-min + compress: + description: "Compress" + steps: + - run: + name: "Compress" + command: | + pushd www/ + tar -cvf artifact.tar * + mv artifact.tar ${OLDPWD}/ + - run: + name: "Tag commit id as artifact identifer" + command: echo "${CIRCLE_SHA1}" > artifact-info.txt + upload_artifact: + description: "upload artifact to s3" + steps: + - s3/copy: + from: artifact.tar + to: 's3://${CONTEXT_ARTIFACT_S3_BUCKET}/${CIRCLE_PROJECT_REPONAME}/' + aws-access-key-id: env_CONTEXT_ARTIFACT_S3_AWS_ACCESS_KEY_ID + aws-secret-access-key: env_CONTEXT_ARTIFACT_S3_AWS_SECRET_ACCESS_KEY + aws-region: env_CONTEXT_ARTIFACT_S3_AWS_REGION + arguments: '--metadata "{\"x-amz-artifact-id\": \"${CIRCLE_SHA1}\" }"' + upload_checksum: + description: "upload artifact commit id to s3" + steps: + - s3/copy: + from: artifact-info.txt + to: 's3://${CONTEXT_ARTIFACT_S3_BUCKET}/${CIRCLE_PROJECT_REPONAME}/' + aws-access-key-id: env_CONTEXT_ARTIFACT_S3_AWS_ACCESS_KEY_ID + aws-secret-access-key: env_CONTEXT_ARTIFACT_S3_AWS_SECRET_ACCESS_KEY + aws-region: env_CONTEXT_ARTIFACT_S3_AWS_REGION + docker: + description: "Build and Push image to docker hub" + parameters: + target: + type: string + steps: + - setup_remote_docker + - run: + name: Building docker image for << parameters.target >> + command: | + build_tag="${CIRCLE_SHA1}" + [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" + docker build -t ${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} -t ${DOCKHUB_ORGANISATION}/ticktrade:latest . + - run: + name: Pushing Image to docker hub + command: | + build_tag="${CIRCLE_SHA1}" + [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" + echo $DOCKERHUB_PASSWORD | docker login -u $DOCKERHUB_USERNAME --password-stdin + docker push ${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} + docker push ${DOCKHUB_ORGANISATION}/ticktrade:latest + k8s_deploy: + description: "Deploy to k8s cluster" + parameters: + target: + type: string + steps: + - k8s/install-kubectl + - run: + name: Deploying to k8s cluster for service binary-bot-beta + command: | + build_tag="${CIRCLE_SHA1}" + deployment_target="ticktrade-binary-com" + [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" && deployment_target="ticktrade-binary-com" + echo $CA_CRT | base64 --decode > ca.crt + kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/${deployment_target} ${deployment_target}=${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} + + npm_test: + description: Run test + steps: + - run: + name: Run tests + command: | + for i in {1..3}; do npm test && break; done + +jobs: + test: + docker: + - image: circleci/node:12.13.0-stretch + steps: + - git_checkout_from_cache + - npm_install + - npm_test + +workflows: + test: + jobs: + - test diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000000..331d38729f --- /dev/null +++ b/.dockerignore @@ -0,0 +1,2 @@ +.git +Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000000..2c3b99394b --- /dev/null +++ b/Dockerfile @@ -0,0 +1,3 @@ +FROM nginx:alpine +COPY ./www /usr/share/nginx/html +COPY ./default.conf /etc/nginx/conf.d/default.conf diff --git a/default.conf b/default.conf new file mode 100644 index 0000000000..758978854f --- /dev/null +++ b/default.conf @@ -0,0 +1,22 @@ +server { + listen 80; + server_name localhost; + + add_header Cache-Control "public, max-age=7200, s-maxage=600, must-revalidate"; + charset UTF-8; + + error_page 404 /404.html; + + location @custom_error_503 { + return 503; + } + + location ~ /\.git { + return 404; + } + + location / { + root /usr/share/nginx/html; + index index.html index.htm; + } +} From f667e775b523f153942690603326bb200de122f9 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 17:45:45 +0800 Subject: [PATCH 03/46] change yarn to npm --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 913fb7f55f..b610587da3 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: yarn + command: npm install - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} From 771e05792e4c06c81e3ace320df49cc50596f3c5 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 18:00:53 +0800 Subject: [PATCH 04/46] change node tag --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b610587da3..a3247d2ba2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -132,7 +132,7 @@ commands: jobs: test: docker: - - image: circleci/node:12.13.0-stretch + - image: circleci/node:chakracore-browsers-legacy steps: - git_checkout_from_cache - npm_install From e8da9c1d9ad110810cea1f3e2fb11755db692596 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 18:19:35 +0800 Subject: [PATCH 05/46] add release_beta workflows --- .circleci/config.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index a3247d2ba2..1669a5787a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -137,8 +137,28 @@ jobs: - git_checkout_from_cache - npm_install - npm_test + release_beta: + docker: + - image: circleci/node:12.13.0-stretch + steps: + - git_checkout_from_cache + - npm_install + - build + - docker: + target: "beta" + - k8s_deploy: + target: "beta" workflows: test: jobs: - test + release: + jobs: + - release_beta: + filters: + branches: + ignore: /.*/ + tags: + only: /V*-beta/ + From b8ff5a65377d1abe9b11e3f60957893ff48f9492 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 18:26:24 +0800 Subject: [PATCH 06/46] change release tag match --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1669a5787a..7e89765f70 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -139,7 +139,7 @@ jobs: - npm_test release_beta: docker: - - image: circleci/node:12.13.0-stretch + - image: circleci/node:chakracore-browsers-legacy steps: - git_checkout_from_cache - npm_install @@ -160,5 +160,5 @@ workflows: branches: ignore: /.*/ tags: - only: /V*-beta/ + only: /*-beta/ From 73feeb8405ff1b9da9ff0098acdacac1207fc8f1 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 18:31:48 +0800 Subject: [PATCH 07/46] change release tag match --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7e89765f70..ccb5f79dea 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -160,5 +160,5 @@ workflows: branches: ignore: /.*/ tags: - only: /*-beta/ + only: /V[0-9]+(\.[0-9]+)*[/]-beta/ From 923268ad6e2bbd0682a14027d1efce79cca5ff1e Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 18:35:39 +0800 Subject: [PATCH 08/46] change release tag match --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ccb5f79dea..45e222ab66 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -160,5 +160,5 @@ workflows: branches: ignore: /.*/ tags: - only: /V[0-9]+(\.[0-9]+)*[/]-beta/ + only: /V[0-9]+(\.[0-9]+)*-beta/ From 7e5ad30778cab7509723cb00a4fd1d8068b0053a Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 18:39:03 +0800 Subject: [PATCH 09/46] change yarn to npm --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 45e222ab66..067960b749 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -51,7 +51,7 @@ commands: description: "Build" steps: - run: - name: "yarn build" + name: "npm build" command: node_modules/gulp/bin/gulp.js build-min compress: description: "Compress" From 12dc4847b0ee6208b409f521acfc498325114a9e Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 19:21:34 +0800 Subject: [PATCH 10/46] change npm to yarn --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 067960b749..45e222ab66 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -51,7 +51,7 @@ commands: description: "Build" steps: - run: - name: "npm build" + name: "yarn build" command: node_modules/gulp/bin/gulp.js build-min compress: description: "Compress" From dab337b5f0d7fb0b1bdde0b758976ee606e4a817 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Sun, 22 Mar 2020 19:26:22 +0800 Subject: [PATCH 11/46] change npm to yarn --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 45e222ab66..221a4813c1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: npm install + command: yarn - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} From d55c37c851ba25cacacf5f3721b8a9692aa47321 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 08:51:30 +0800 Subject: [PATCH 12/46] change build command --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 221a4813c1..cb514394a2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -52,7 +52,7 @@ commands: steps: - run: name: "yarn build" - command: node_modules/gulp/bin/gulp.js build-min + command: node_modules/gulp/bin/gulp.js build-desktop --platform=linux --arch=x64 compress: description: "Compress" steps: From 3ae630cb23b1e1f47aa48d7fe02b14c7e6220bc2 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 09:17:38 +0800 Subject: [PATCH 13/46] change build image --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index cb514394a2..6422779585 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -139,7 +139,7 @@ jobs: - npm_test release_beta: docker: - - image: circleci/node:chakracore-browsers-legacy + - image: circleci/node:lts-stretch steps: - git_checkout_from_cache - npm_install From 9f159dbbb98038a362de375abdf2783e05f85f03 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 09:53:47 +0800 Subject: [PATCH 14/46] change build image --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6422779585..cb514394a2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -139,7 +139,7 @@ jobs: - npm_test release_beta: docker: - - image: circleci/node:lts-stretch + - image: circleci/node:chakracore-browsers-legacy steps: - git_checkout_from_cache - npm_install From c6232b5fd6244a72b0cb96a03f108d60c8ccc8c4 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 10:07:22 +0800 Subject: [PATCH 15/46] test build --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index cb514394a2..ffdfad772e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -52,7 +52,7 @@ commands: steps: - run: name: "yarn build" - command: node_modules/gulp/bin/gulp.js build-desktop --platform=linux --arch=x64 + command: node_modules/gulp/bin/gulp.js -h && node_modules/gulp/bin/gulp.js build-desktop --platform=linux --arch=x64 compress: description: "Compress" steps: From 95271d6baa6112fcecca1d311af19cd8b3f59e9a Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 10:15:58 +0800 Subject: [PATCH 16/46] test build --- .circleci/config.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ffdfad772e..aed8fc7158 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,9 @@ commands: - npm-v1- - run: name: Install npm modules - command: yarn + command: npm install -g bower gulp cordova ionic ios-sim + npm install + yarn - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} @@ -52,7 +54,7 @@ commands: steps: - run: name: "yarn build" - command: node_modules/gulp/bin/gulp.js -h && node_modules/gulp/bin/gulp.js build-desktop --platform=linux --arch=x64 + command: node_modules/gulp/bin/gulp.js build-desktop --platform=linux --arch=x64 compress: description: "Compress" steps: From ac552965ce0eb986b73e067433db6e3b3ae0d4b2 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 10:21:15 +0800 Subject: [PATCH 17/46] change build image --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index aed8fc7158..e290b03b77 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -141,7 +141,7 @@ jobs: - npm_test release_beta: docker: - - image: circleci/node:chakracore-browsers-legacy + - image: circleci/node:lts-stretch steps: - git_checkout_from_cache - npm_install From bf9eb5274cb7f915114e9f3c51091859736ac6f3 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 10:36:09 +0800 Subject: [PATCH 18/46] build test --- .circleci/config.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index e290b03b77..c09d67f961 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,9 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: npm install -g bower gulp cordova ionic ios-sim - npm install - yarn + command: npm install -g bower gulp cordova ionic ios-sim && npm install - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} @@ -54,7 +52,7 @@ commands: steps: - run: name: "yarn build" - command: node_modules/gulp/bin/gulp.js build-desktop --platform=linux --arch=x64 + command: gulp build-desktop --platform=linux --arch=x64 compress: description: "Compress" steps: @@ -134,7 +132,7 @@ commands: jobs: test: docker: - - image: circleci/node:chakracore-browsers-legacy + - image: circleci/node:lts-stretch steps: - git_checkout_from_cache - npm_install From 11fe5f27bbdbd299642f7903d1c26ec82ef57d1d Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 10:52:28 +0800 Subject: [PATCH 19/46] change image --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c09d67f961..b2897f9da9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -132,7 +132,7 @@ commands: jobs: test: docker: - - image: circleci/node:lts-stretch + - image: phantasm/node:lts-stretch steps: - git_checkout_from_cache - npm_install From bc6f4afa573280c908c5ea518fdac982af828bb8 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 11:07:55 +0800 Subject: [PATCH 20/46] build test --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b2897f9da9..ef9a7e2476 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: npm install -g bower gulp cordova ionic ios-sim && npm install + command: yarn - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} @@ -139,7 +139,7 @@ jobs: - npm_test release_beta: docker: - - image: circleci/node:lts-stretch + - image: phantasm/node:lts-stretch steps: - git_checkout_from_cache - npm_install From bb7786ce181717a85a46d67f7053098b70268c45 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 11:15:57 +0800 Subject: [PATCH 21/46] build test --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ef9a7e2476..1e7da46ad4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: yarn + command: npm install electron electron-packager - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} From 5d0167602dc39767c778b18a366aad97676015b6 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 11:19:17 +0800 Subject: [PATCH 22/46] build test --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1e7da46ad4..4b762717cf 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: npm install electron electron-packager + command: npm install - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} From 0f6cc6f1ab0555f49d34304be80edf27b5ed31c6 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 11:27:32 +0800 Subject: [PATCH 23/46] change image --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 4b762717cf..c3b8e520ad 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -132,7 +132,7 @@ commands: jobs: test: docker: - - image: phantasm/node:lts-stretch + - image: circleci/node:chakracore-browsers-legacy steps: - git_checkout_from_cache - npm_install From 48ddf91de23d4cda8d1641dd9033a582e5901f24 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 15:37:15 +0800 Subject: [PATCH 24/46] change image to 11.15.0 --- .circleci/config.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c3b8e520ad..0b399c2805 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -41,7 +41,7 @@ commands: - npm-v1- - run: name: Install npm modules - command: npm install + command: npm install && ./node_modules/.bin/bower install - save_cache: name: Save NPM cache key: npm-v1-{{ checksum "package.json" }} @@ -52,7 +52,7 @@ commands: steps: - run: name: "yarn build" - command: gulp build-desktop --platform=linux --arch=x64 + command: ./node_modules/.bin/gulp build compress: description: "Compress" steps: @@ -132,14 +132,14 @@ commands: jobs: test: docker: - - image: circleci/node:chakracore-browsers-legacy + - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install - npm_test release_beta: docker: - - image: phantasm/node:lts-stretch + - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install From 3b94d51db4d835248dfc23f600552c72ba5bcfe2 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 16:28:07 +0800 Subject: [PATCH 25/46] add production release workflow --- .circleci/config.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0b399c2805..18cdfc8922 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -148,6 +148,20 @@ jobs: target: "beta" - k8s_deploy: target: "beta" + release_production: + docker: + - image: circleci/node:12.13.0-stretch + steps: + - git_checkout_from_cache + - npm_install + - build + - compress + - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment + - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment + - docker: + target: "production" + - k8s_deploy: + target: "production" workflows: test: @@ -161,4 +175,10 @@ workflows: ignore: /.*/ tags: only: /V[0-9]+(\.[0-9]+)*-beta/ + - release: + filters: + branches: + ignore: /.*/ + tags: + only: /V[0-9]+(\.[0-9]+)2/ From 2757046c764473eb33037f673d31d3115546c3c9 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 16:38:02 +0800 Subject: [PATCH 26/46] fix production release workflow & add context --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 18cdfc8922..fa56a2eed2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -175,10 +175,10 @@ workflows: ignore: /.*/ tags: only: /V[0-9]+(\.[0-9]+)*-beta/ - - release: + - release_production: filters: branches: ignore: /.*/ tags: only: /V[0-9]+(\.[0-9]+)2/ - + context: ticktrade-binary-artifact-upload From d9cb4f3e5a6718bba78dc719835ae041ce6198e6 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 16:40:34 +0800 Subject: [PATCH 27/46] fix yaml --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index fa56a2eed2..a476ec5205 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -181,4 +181,4 @@ workflows: ignore: /.*/ tags: only: /V[0-9]+(\.[0-9]+)2/ - context: ticktrade-binary-artifact-upload + context: ticktrade-binary-artifact-upload From b907608332209ffb0e496306db495a9e6f06a33a Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 16:52:15 +0800 Subject: [PATCH 28/46] fix tag --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index a476ec5205..636b181e77 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -180,5 +180,5 @@ workflows: branches: ignore: /.*/ tags: - only: /V[0-9]+(\.[0-9]+)2/ + only: /V[0-9]+(\.[0-9]+)*/ context: ticktrade-binary-artifact-upload From 9b30ae6c8d6cd922e851abedf67f22548d0aa3e1 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 17:03:32 +0800 Subject: [PATCH 29/46] fix node version --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 636b181e77..b2ed6088fe 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -150,7 +150,7 @@ jobs: target: "beta" release_production: docker: - - image: circleci/node:12.13.0-stretch + - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install From a5665f27fc2791126ce855940998d4c5ed549f49 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 17:11:50 +0800 Subject: [PATCH 30/46] workflow test --- .circleci/config.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b2ed6088fe..df7842fae2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -51,7 +51,7 @@ commands: description: "Build" steps: - run: - name: "yarn build" + name: "gulp build" command: ./node_modules/.bin/gulp build compress: description: "Compress" @@ -155,9 +155,9 @@ jobs: - git_checkout_from_cache - npm_install - build - - compress - - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment - - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment + # - compress + # - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment + # - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment - docker: target: "production" - k8s_deploy: From b41b1bcda26cad54d6c2d73987f8e3fc1bd05948 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 23 Mar 2020 17:22:47 +0800 Subject: [PATCH 31/46] add circleci pipeline --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index df7842fae2..93d01858ec 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -155,9 +155,9 @@ jobs: - git_checkout_from_cache - npm_install - build - # - compress - # - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment - # - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment + - compress + - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment + - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment - docker: target: "production" - k8s_deploy: From 51fda024e7807c00c7090711f48a451a33a14262 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Tue, 24 Mar 2020 14:28:14 +0800 Subject: [PATCH 32/46] change context --- .circleci/config.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 93d01858ec..65706e5959 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -103,8 +103,7 @@ commands: build_tag="${CIRCLE_SHA1}" [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" echo $DOCKERHUB_PASSWORD | docker login -u $DOCKERHUB_USERNAME --password-stdin - docker push ${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} - docker push ${DOCKHUB_ORGANISATION}/ticktrade:latest + docker push ${DOCKHUB_ORGANISATION}/ticktrade k8s_deploy: description: "Deploy to k8s cluster" parameters: @@ -181,4 +180,4 @@ workflows: ignore: /.*/ tags: only: /V[0-9]+(\.[0-9]+)*/ - context: ticktrade-binary-artifact-upload + context: binary-frontend-artifact-upload From 3401f5fb6dc9a83b35ea98a1e63845e11b2bd905 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Tue, 24 Mar 2020 16:55:04 +0800 Subject: [PATCH 33/46] Add Release pattern to README --- README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/README.md b/README.md index 07267f32fb..6d259fb261 100644 --- a/README.md +++ b/README.md @@ -91,3 +91,23 @@ gulp deploy-translation (--remote ) 1. run `npm install` to install `karam`, `jasmine` and all other dependencies. 2. run `npm install -g karma-cli` 3. run 'karma start` + +## Release + +``` +git tag ${RELEASE_TARGET}_vYYYYMMDD_${INTEGER} -m 'some message' +``` + +> `RELEASE_TARGET` could be one of **staging** or **production** for staging and production release respectively. + +Example: + +``` +git tag production_v20191010_0 -m 'release fixes to production' +``` + +Push the tag: + +``` +git push origin staging_v20191010_0 +``` From dc3f4ca9873c421b111dc8f3b15a580c4ff8950d Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 09:08:14 +0800 Subject: [PATCH 34/46] add release format and workflow --- .circleci/config.yml | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 65706e5959..9554fba3a1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -89,36 +89,36 @@ commands: parameters: target: type: string + default: "staging" steps: - setup_remote_docker - run: name: Building docker image for << parameters.target >> command: | - build_tag="${CIRCLE_SHA1}" - [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" - docker build -t ${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} -t ${DOCKHUB_ORGANISATION}/ticktrade:latest . + build_tag="${target}-${CIRCLE_TAG}" + docker build -t ${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} -t ${DOCKHUB_ORGANISATION}/ticktrade:${target}-latest . - run: name: Pushing Image to docker hub command: | - build_tag="${CIRCLE_SHA1}" - [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" echo $DOCKERHUB_PASSWORD | docker login -u $DOCKERHUB_USERNAME --password-stdin docker push ${DOCKHUB_ORGANISATION}/ticktrade k8s_deploy: description: "Deploy to k8s cluster" parameters: + k8s_svc_name: + type: string + default: "staging-ticktrade-binary-com" target: type: string + default: "staging" steps: - k8s/install-kubectl - run: - name: Deploying to k8s cluster for service binary-bot-beta + name: Deploying to k8s cluster for service << parameters.k8s_svc_name >> command: | - build_tag="${CIRCLE_SHA1}" - deployment_target="ticktrade-binary-com" - [ "<< parameters.target >>" == "beta" ] && build_tag="beta-${CIRCLE_SHA1}" && deployment_target="ticktrade-binary-com" + build_tag="${target}-${CIRCLE_TAG}" echo $CA_CRT | base64 --decode > ca.crt - kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/${deployment_target} ${deployment_target}=${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} + kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} npm_test: description: Run test @@ -136,7 +136,7 @@ jobs: - git_checkout_from_cache - npm_install - npm_test - release_beta: + release_staging: docker: - image: circleci/node:11.15.0 steps: @@ -144,9 +144,10 @@ jobs: - npm_install - build - docker: - target: "beta" + target: "staging" - k8s_deploy: - target: "beta" + k8s_svc_name: "staging-ticktrade-binary-com" + target: "staging" release_production: docker: - image: circleci/node:11.15.0 @@ -160,6 +161,7 @@ jobs: - docker: target: "production" - k8s_deploy: + k8s_svc_name: "production-ticktrade-binary-com" target: "production" workflows: @@ -168,16 +170,16 @@ workflows: - test release: jobs: - - release_beta: + - release_staging: filters: branches: ignore: /.*/ tags: - only: /V[0-9]+(\.[0-9]+)*-beta/ + only: /^staging.*/ - release_production: filters: branches: ignore: /.*/ tags: - only: /V[0-9]+(\.[0-9]+)*/ + only: /^production.*/ context: binary-frontend-artifact-upload From 2a958c5184af30de6021453aa94d100a19c3897b Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 09:29:04 +0800 Subject: [PATCH 35/46] fix docker build tag --- .circleci/config.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9554fba3a1..62e7a90f5e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -95,8 +95,7 @@ commands: - run: name: Building docker image for << parameters.target >> command: | - build_tag="${target}-${CIRCLE_TAG}" - docker build -t ${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} -t ${DOCKHUB_ORGANISATION}/ticktrade:${target}-latest . + docker build -t ${DOCKHUB_ORGANISATION}/ticktrade:${CIRCLE_TAG} -t ${DOCKHUB_ORGANISATION}/ticktrade:<< parameters.target >>-latest . - run: name: Pushing Image to docker hub command: | From 1866f1e89ae2502d2375bff766ff21b466ed487b Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 09:48:37 +0800 Subject: [PATCH 36/46] fix k8s workflow --- .circleci/config.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 62e7a90f5e..7b3966688c 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -107,17 +107,13 @@ commands: k8s_svc_name: type: string default: "staging-ticktrade-binary-com" - target: - type: string - default: "staging" steps: - k8s/install-kubectl - run: name: Deploying to k8s cluster for service << parameters.k8s_svc_name >> command: | - build_tag="${target}-${CIRCLE_TAG}" echo $CA_CRT | base64 --decode > ca.crt - kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade:${build_tag} + kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade:${CIRCLE_TAG} npm_test: description: Run test @@ -146,7 +142,6 @@ jobs: target: "staging" - k8s_deploy: k8s_svc_name: "staging-ticktrade-binary-com" - target: "staging" release_production: docker: - image: circleci/node:11.15.0 @@ -161,7 +156,6 @@ jobs: target: "production" - k8s_deploy: k8s_svc_name: "production-ticktrade-binary-com" - target: "production" workflows: test: From bf789099f30270dcaab5aee0636ae29dfabd4f5b Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 09:58:27 +0800 Subject: [PATCH 37/46] change upload artifact tag --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7b3966688c..7c3f4d54e0 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -64,7 +64,7 @@ commands: mv artifact.tar ${OLDPWD}/ - run: name: "Tag commit id as artifact identifer" - command: echo "${CIRCLE_SHA1}" > artifact-info.txt + command: echo "${CIRCLE_TAG}" > artifact-info.txt upload_artifact: description: "upload artifact to s3" steps: @@ -74,7 +74,7 @@ commands: aws-access-key-id: env_CONTEXT_ARTIFACT_S3_AWS_ACCESS_KEY_ID aws-secret-access-key: env_CONTEXT_ARTIFACT_S3_AWS_SECRET_ACCESS_KEY aws-region: env_CONTEXT_ARTIFACT_S3_AWS_REGION - arguments: '--metadata "{\"x-amz-artifact-id\": \"${CIRCLE_SHA1}\" }"' + arguments: '--metadata "{\"x-amz-artifact-id\": \"${CIRCLE_TAG}\" }"' upload_checksum: description: "upload artifact commit id to s3" steps: From 39f75e63552188917b65a41576615a70f8e08e20 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 10:07:26 +0800 Subject: [PATCH 38/46] test circleci workflow --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7c3f4d54e0..3ebf883303 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -150,8 +150,8 @@ jobs: - npm_install - build - compress - - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment - - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment + # - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment + #- upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment - docker: target: "production" - k8s_deploy: From 4afacf1fc1aecf6f059d431693b1c02ae87ebef1 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 10:21:22 +0800 Subject: [PATCH 39/46] fix circleci workflow --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3ebf883303..7c3f4d54e0 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -150,8 +150,8 @@ jobs: - npm_install - build - compress - # - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment - #- upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment + - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment + - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment - docker: target: "production" - k8s_deploy: From 363d91b97b4ba9f4a300e221d7c57fc165ba0a47 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 15:16:25 +0800 Subject: [PATCH 40/46] multiple clusters --- .circleci/config.yml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7c3f4d54e0..6b2044c001 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -112,8 +112,21 @@ commands: - run: name: Deploying to k8s cluster for service << parameters.k8s_svc_name >> command: | - echo $CA_CRT | base64 --decode > ca.crt - kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade:${CIRCLE_TAG} + for SERVER_ID in {1..5} + do + KUBE_SERVER_REF="KUBE_SERVER_$SERVER_ID" + SERVICEACCOUNT_TOKEN_REF="SERVICEACCOUNT_TOKEN_$SERVER_ID" + CA_CRT_REF="CA_CRT_$SERVER_ID" + if [ ! -z "${!KUBE_SERVER_REF}" ] + then + echo "Deploying to cluster $SERVER_ID" + CA_CRT="${!CA_CRT_REF}" + KUBE_SERVER="${!KUBE_SERVER_REF}" + SERVICEACCOUNT_TOKEN="${!SERVICEACCOUNT_TOKEN_REF}" + echo $CA_CRT | base64 --decode > ca.crt + kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade:${CIRCLE_TAG} + fi + done npm_test: description: Run test From 0a26caa130075aae16c83492499ce3c463f76c53 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 18:43:51 +0800 Subject: [PATCH 41/46] add context to staging --- .circleci/config.yml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6b2044c001..53fc717f6a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -84,7 +84,7 @@ commands: aws-access-key-id: env_CONTEXT_ARTIFACT_S3_AWS_ACCESS_KEY_ID aws-secret-access-key: env_CONTEXT_ARTIFACT_S3_AWS_SECRET_ACCESS_KEY aws-region: env_CONTEXT_ARTIFACT_S3_AWS_REGION - docker: + docker_build_push: description: "Build and Push image to docker hub" parameters: target: @@ -138,25 +138,25 @@ commands: jobs: test: - docker: + docker_build_push: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install - npm_test release_staging: - docker: + docker_build_push: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install - build - - docker: + - docker_build_push: target: "staging" - k8s_deploy: k8s_svc_name: "staging-ticktrade-binary-com" release_production: - docker: + docker_build_push: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache @@ -165,7 +165,7 @@ jobs: - compress - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment - - docker: + - docker_build_push: target: "production" - k8s_deploy: k8s_svc_name: "production-ticktrade-binary-com" @@ -182,6 +182,7 @@ workflows: ignore: /.*/ tags: only: /^staging.*/ + context: binary-frontend-artifact-upload - release_production: filters: branches: From 322c128b15bd20ee1731d34c2a6c05e9196268eb Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Wed, 25 Mar 2020 18:49:08 +0800 Subject: [PATCH 42/46] rename step docker_build_push --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 53fc717f6a..f100990a8a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -138,14 +138,14 @@ commands: jobs: test: - docker_build_push: + docker: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install - npm_test release_staging: - docker_build_push: + docker: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache @@ -156,7 +156,7 @@ jobs: - k8s_deploy: k8s_svc_name: "staging-ticktrade-binary-com" release_production: - docker_build_push: + docker: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache From 10c7585ee54e90eb4148cd63b4aed4657949df36 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 30 Mar 2020 09:18:47 +0800 Subject: [PATCH 43/46] circleci master/dev release --- .circleci/config.yml | 58 +++++++++----------------------------------- 1 file changed, 12 insertions(+), 46 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index f100990a8a..644f37e799 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -86,31 +86,23 @@ commands: aws-region: env_CONTEXT_ARTIFACT_S3_AWS_REGION docker_build_push: description: "Build and Push image to docker hub" - parameters: - target: - type: string - default: "staging" steps: - setup_remote_docker - run: - name: Building docker image for << parameters.target >> + name: Building docker image for production command: | - docker build -t ${DOCKHUB_ORGANISATION}/ticktrade:${CIRCLE_TAG} -t ${DOCKHUB_ORGANISATION}/ticktrade:<< parameters.target >>-latest . + docker build -t ${DOCKHUB_ORGANISATION}/ticktrade-mobile:${CIRCLE_TAG} -t ${DOCKHUB_ORGANISATION}/ticktrade-mobile:latest . - run: name: Pushing Image to docker hub command: | echo $DOCKERHUB_PASSWORD | docker login -u $DOCKERHUB_USERNAME --password-stdin - docker push ${DOCKHUB_ORGANISATION}/ticktrade + docker push ${DOCKHUB_ORGANISATION}/ticktrade-mobile k8s_deploy: description: "Deploy to k8s cluster" - parameters: - k8s_svc_name: - type: string - default: "staging-ticktrade-binary-com" steps: - k8s/install-kubectl - run: - name: Deploying to k8s cluster for service << parameters.k8s_svc_name >> + name: Deploying to k8s cluster for service production-ticktrade-binary-com command: | for SERVER_ID in {1..5} do @@ -124,37 +116,19 @@ commands: KUBE_SERVER="${!KUBE_SERVER_REF}" SERVICEACCOUNT_TOKEN="${!SERVICEACCOUNT_TOKEN_REF}" echo $CA_CRT | base64 --decode > ca.crt - kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade:${CIRCLE_TAG} + kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade-mobile:${CIRCLE_SHA1} fi done - npm_test: - description: Run test - steps: - - run: - name: Run tests - command: | - for i in {1..3}; do npm test && break; done jobs: test: - docker: - - image: circleci/node:11.15.0 - steps: - - git_checkout_from_cache - - npm_install - - npm_test - release_staging: docker: - image: circleci/node:11.15.0 steps: - git_checkout_from_cache - npm_install - build - - docker_build_push: - target: "staging" - - k8s_deploy: - k8s_svc_name: "staging-ticktrade-binary-com" release_production: docker: - image: circleci/node:11.15.0 @@ -165,28 +139,20 @@ jobs: - compress - upload_artifact # uploading the built code to s3 to create a backup of key services separate from Kubernetes deployment - upload_checksum # uploading compressed artifact checksum to cross match artifact fingerprint before actual deployment - - docker_build_push: - target: "production" - - k8s_deploy: - k8s_svc_name: "production-ticktrade-binary-com" + - docker_build_push + - k8s_deploy workflows: test: jobs: - - test - release: - jobs: - - release_staging: + - test: filters: branches: - ignore: /.*/ - tags: - only: /^staging.*/ - context: binary-frontend-artifact-upload + ignore: /^master$/ + release: + jobs: - release_production: filters: branches: - ignore: /.*/ - tags: - only: /^production.*/ + only: /^master$/ context: binary-frontend-artifact-upload From 38548ca0334de3ced771b6577e83e15500d71b0e Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 30 Mar 2020 09:28:36 +0800 Subject: [PATCH 44/46] release does't always TAG --- .circleci/config.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 644f37e799..3957febb76 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -64,7 +64,7 @@ commands: mv artifact.tar ${OLDPWD}/ - run: name: "Tag commit id as artifact identifer" - command: echo "${CIRCLE_TAG}" > artifact-info.txt + command: echo "${CIRCLE_SHA1}" > artifact-info.txt upload_artifact: description: "upload artifact to s3" steps: @@ -74,7 +74,7 @@ commands: aws-access-key-id: env_CONTEXT_ARTIFACT_S3_AWS_ACCESS_KEY_ID aws-secret-access-key: env_CONTEXT_ARTIFACT_S3_AWS_SECRET_ACCESS_KEY aws-region: env_CONTEXT_ARTIFACT_S3_AWS_REGION - arguments: '--metadata "{\"x-amz-artifact-id\": \"${CIRCLE_TAG}\" }"' + arguments: '--metadata "{\"x-amz-artifact-id\": \"${CIRCLE_SHA1}\" }"' upload_checksum: description: "upload artifact commit id to s3" steps: @@ -91,7 +91,7 @@ commands: - run: name: Building docker image for production command: | - docker build -t ${DOCKHUB_ORGANISATION}/ticktrade-mobile:${CIRCLE_TAG} -t ${DOCKHUB_ORGANISATION}/ticktrade-mobile:latest . + docker build -t ${DOCKHUB_ORGANISATION}/ticktrade-mobile:${CIRCLE_SHA1} -t ${DOCKHUB_ORGANISATION}/ticktrade-mobile:latest . - run: name: Pushing Image to docker hub command: | @@ -102,7 +102,7 @@ commands: steps: - k8s/install-kubectl - run: - name: Deploying to k8s cluster for service production-ticktrade-binary-com + name: Deploying to k8s cluster for service ticktrade-binary-com command: | for SERVER_ID in {1..5} do @@ -116,7 +116,7 @@ commands: KUBE_SERVER="${!KUBE_SERVER_REF}" SERVICEACCOUNT_TOKEN="${!SERVICEACCOUNT_TOKEN_REF}" echo $CA_CRT | base64 --decode > ca.crt - kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/<< parameters.k8s_svc_name >> << parameters.k8s_svc_name >>=${DOCKHUB_ORGANISATION}/ticktrade-mobile:${CIRCLE_SHA1} + kubectl --server=${KUBE_SERVER} --certificate-authority=ca.crt --token=$SERVICEACCOUNT_TOKEN set image deployment/ticktrade-binary-com ticktrade-binary-com=${DOCKHUB_ORGANISATION}/ticktrade-mobile:${CIRCLE_SHA1} fi done From fd91f1800f525197bcbc9b86b57300e513de322a Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 30 Mar 2020 09:50:38 +0800 Subject: [PATCH 45/46] edit README --- README.md | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/README.md b/README.md index 6d259fb261..07267f32fb 100644 --- a/README.md +++ b/README.md @@ -91,23 +91,3 @@ gulp deploy-translation (--remote ) 1. run `npm install` to install `karam`, `jasmine` and all other dependencies. 2. run `npm install -g karma-cli` 3. run 'karma start` - -## Release - -``` -git tag ${RELEASE_TARGET}_vYYYYMMDD_${INTEGER} -m 'some message' -``` - -> `RELEASE_TARGET` could be one of **staging** or **production** for staging and production release respectively. - -Example: - -``` -git tag production_v20191010_0 -m 'release fixes to production' -``` - -Push the tag: - -``` -git push origin staging_v20191010_0 -``` From 8ae4fed9f67a4e6055ef9f01e82ca2eb30adc805 Mon Sep 17 00:00:00 2001 From: Afshin Paydar Date: Mon, 30 Mar 2020 12:08:14 +0800 Subject: [PATCH 46/46] change gulp build --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3957febb76..5b29014c63 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -52,7 +52,7 @@ commands: steps: - run: name: "gulp build" - command: ./node_modules/.bin/gulp build + command: npx gulp build compress: description: "Compress" steps: