-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
43 lines (34 loc) · 1.12 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
stages:
- build
variables:
VAULT_ADDR: "https://vault.aktivco.ru"
TART_IMAGE: tart-hosted.aktivco.ru/rutoken/macos:2.2.0
LC_ALL: en_US.UTF-8
LANG: en_US.UTF-8
.vault_provision_secrets: &vault_secrets
- PROJECT_ROLE="ci-swift-package"
- export VAULT_TOKEN="$(vault write -field=token auth/jwt/login role=${PROJECT_ROLE} jwt=${VAULT_JWT_TOKEN})"
- SSH_PRIVATE_KEY="${HOME}/.ssh/id_rsa"
- vault kv get -field=private ci/apple/identity/ssh-key > ${SSH_PRIVATE_KEY}
- chmod 0600 ${SSH_PRIVATE_KEY}
- vault token revoke -self
build:
stage: build
tags: [tart-darwin]
image: $TART_IMAGE
variables:
RT_CI_VAGRANT_BOX_CPUS: 2
RT_CI_VAGRANT_BOX_MEMORY: 4096
id_tokens:
VAULT_JWT_TOKEN:
aud: https://vault.aktivco.ru
before_script:
- *vault_secrets
- ip=$(dig scm.aktivco.ru +short)
- ssh-keyscan scm.aktivco.ru,$ip >> ~/.ssh/known_hosts
script:
- |
xcodebuild clean build -scheme rt-ui-components \
-skipPackagePluginValidation \
-destination generic/platform=iOS \
-scmProvider system