-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Generate author certificate and security profile manually.
* Remove automatic certificate generation and security profiles with hardcoded passwords from docker images. * Describe building the Tizen lighting-app app with the author certificate and security profile generation process.
- Loading branch information
Showing
3 changed files
with
43 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -83,15 +83,3 @@ RUN sed -i '/^TIZEN_SDK_DATA_PATH/d' $TIZEN_SDK_ROOT/sdk.info \ | |
&& echo TIZEN_SDK_DATA_PATH=/home/$USERNAME/tizen-sdk-data >> $TIZEN_SDK_ROOT/sdk.info \ | ||
&& ln -sf /home/$USERNAME/.tizen-cli-config $TIZEN_SDK_ROOT/tools/.tizen-cli-config \ | ||
&& : # last line | ||
|
||
USER $USERNAME | ||
WORKDIR /home/$USERNAME | ||
|
||
# Setup tizen studio CLI | ||
RUN set -x \ | ||
# Generate authr certificate | ||
&& $TIZEN_SDK_ROOT/tools/ide/bin/tizen certificate --alias=CHIP --name=CHIP [email protected] --password=chiptizen \ | ||
# Add new security profile | ||
&& $TIZEN_SDK_ROOT/tools/ide/bin/tizen security-profiles add --active --name=CHIP --author=$HOME/tizen-sdk-data/keystore/author/author.p12 --password=chiptizen \ | ||
# Cleanup | ||
&& : # last line |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,48 @@ | ||
# CHIP Tizen Lighting Example | ||
|
||
## Building binary | ||
|
||
Activating environment | ||
|
||
```sh | ||
source ./scripts/activate.sh | ||
``` | ||
|
||
Generating tizen-arm-light | ||
|
||
```sh | ||
gn gen --check \ | ||
--fail-on-unused-args \ | ||
--export-compile-commands \ | ||
--root=$PW_PROJECT_ROOT/examples/lighting-app/tizen \ | ||
"--args=target_os=\"tizen\" target_cpu=\"arm\" tizen_sdk_root=\"$TIZEN_SDK_ROOT\" sysroot=\"$TIZEN_SDK_SYSROOT\"" \ | ||
$PW_PROJECT_ROOT/out/tizen-arm-light | ||
``` | ||
|
||
Building tizen-arm-light | ||
|
||
```sh | ||
ninja -C $PW_PROJECT_ROOT/out/tizen-arm-light | ||
``` | ||
|
||
## Preparing Tizen SDK certificate | ||
|
||
For packaging the Tizen APP, there is a need to generate an author certificate | ||
and security profile using the commands described below. Change password and | ||
author data as needed. | ||
|
||
```sh | ||
tizen certificate --alias=CHIP --name=CHIP [email protected] --password=chiptizen | ||
|
||
tizen security-profiles add --active --name=CHIP --author=$HOME/tizen-sdk-data/keystore/author/author.p12 --password=chiptizen | ||
``` | ||
|
||
## Packaging APP | ||
|
||
```sh | ||
ninja -C $PW_PROJECT_ROOT/out/tizen-arm-light chip-lighting-app:tpk | ||
``` | ||
|
||
## Installing TPK | ||
|
||
Upload TPK package to device under test (DUT). Install it with `pkgcmd` as | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -147,13 +147,3 @@ RUN set -x \ | |
# Switch to the non-root user | ||
USER $USER_NAME | ||
WORKDIR $USER_HOME | ||
|
||
# ------------------------------------------------------------------------------ | ||
# Setup tizen studio CLI | ||
RUN set -x \ | ||
# Generate author certificate | ||
&& tizen certificate --alias=CHIP --name=CHIP [email protected] --password=chiptizen \ | ||
# Add new security profile | ||
&& tizen security-profiles add --active --name=CHIP --author=$HOME/tizen-sdk-data/keystore/author/author.p12 --password=chiptizen \ | ||
# Cleanup | ||
&& : # last line |