Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
scl
boilerplate
mobile-moko-boilerplate
Commits
34a4e8a1
Commit
34a4e8a1
authored
Sep 21, 2021
by
Aleksey Mikhailov
🗻
Browse files
setup scripts and readme
parent
13e1c8a2
Changes
3
Hide whitespace changes
Inline
Side-by-side
README.md
View file @
34a4e8a1
...
...
@@ -12,12 +12,27 @@ Project created on base of https://github.com/icerockdev/moko-template.
-
cocoapods 1.10+ (on macos)
-
xcode command line tools (on macos -
`xcode-select --install`
)
# Init Firebase project
# Setup
## Setup apps in Firebase
-
Install
[
Firebase CLI
](
https://firebase.google.com/docs/cli
)
-
run setup script -
`./firebase-
setup.sh <PROJECT_ID> <APPLICATION_ID
>`
-
run setup script -
`./
setup-
firebase-
apps.sh <firebase_project_id> <bundle_id
>`
-
download
`google-services.json`
to
`android-app/google-services.json`
-
download all
`GoogleService-Info.plist`
to
`ios-app/src/Firebase/GoogleService-Info-APPLICATION_ID.plist`
-
download all
`GoogleService-Info.plist`
to
`ios-app/src/Firebase/GoogleService-Info-<bundle_id>.plist`
## Setup android signing
-
Call
`./setup-android-signing.sh <key_name> <gitlab_token> <gitlab_project_id>`
-
commit and push created file
## Setup Firebase deploy
-
run
`firebase logic:ci`
-
copy token from results
-
call
`./setup-android-signing.sh <gitlab_token> <gitlab_project_id> <firebase_token>`
-
In the App Distribution page of the Firebase console, select the app you want to distribute, then click
`Get started`
-
now you can deploy apps by CI
# Build
...
...
setup-firebase-deploy.sh
0 → 100755
View file @
34a4e8a1
#!/bin/bash
set
-euo
pipefail
GITLAB_TOKEN
=
$1
GITLAB_PROJECT_ID
=
$2
FIREBASE_TOKEN
=
$3
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=FIREBASE_TOKEN"
--form
"value=
$FIREBASE_TOKEN
"
setup-ios-ci.sh
0 → 100755
View file @
34a4e8a1
#!/bin/bash
set
-euo
pipefail
GITLAB_TOKEN
=
$1
GITLAB_PROJECT_ID
=
$2
FASTLANE_PASSWORD
=
$3
MATCH_PASSWORD
=
$4
FASTLANE_USER
=
"apple@icerockdev.com"
FASTLANE_TEAM_ID
=
"RF9T8S9829"
MATCH_GIT_BRANCH
=
"mobiledevelopment"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=FASTLANE_PASSWORD"
--form
"value=
$FASTLANE_PASSWORD
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=FASTLANE_USER"
--form
"value=
$FASTLANE_USER
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=MATCH_PASSWORD"
--form
"value=
$MATCH_PASSWORD
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=FASTLANE_TEAM_ID_DEV"
--form
"value=
$FASTLANE_TEAM_ID
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=FASTLANE_TEAM_ID_STAGE"
--form
"value=
$FASTLANE_TEAM_ID
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=FASTLANE_TEAM_ID_PROD"
--form
"value=
$FASTLANE_TEAM_ID
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=MATCH_GIT_BRANCH_DEV"
--form
"value=
$MATCH_GIT_BRANCH
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=MATCH_GIT_BRANCH_STAGE"
--form
"value=
$MATCH_GIT_BRANCH
"
curl
--request
POST
--header
"PRIVATE-TOKEN:
$GITLAB_TOKEN
"
\
"https://gitlab.icerockdev.com/api/v4/projects/
$GITLAB_PROJECT_ID
/variables"
\
--form
"key=MATCH_GIT_BRANCH_PROD"
--form
"value=
$MATCH_GIT_BRANCH
"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment