diff options
-rw-r--r-- | README.adoc | 10 | ||||
-rw-r--r-- | classes/image_types_ostree.bbclass | 2 | ||||
-rw-r--r-- | recipes-sota/aktualizr/aktualizr-native_git.bb | 6 | ||||
-rw-r--r-- | recipes-sota/aktualizr/aktualizr_common.inc | 2 | ||||
-rw-r--r-- | recipes-sota/sota-tools/sota-tools_git.bb | 24 |
5 files changed, 11 insertions, 33 deletions
diff --git a/README.adoc b/README.adoc index 9615f65..47c0a2b 100644 --- a/README.adoc +++ b/README.adoc | |||
@@ -71,7 +71,7 @@ Although we have used U-Boot so far, other boot loaders can be configured work w | |||
71 | * OSTREE_BRANCHNAME - the branch your rootfs will be committed to. Defaults to "ota" | 71 | * OSTREE_BRANCHNAME - the branch your rootfs will be committed to. Defaults to "ota" |
72 | * OSTREE_OSNAME - OS deployment name on your target device. For more information about deployments and osnames see the https://ostree.readthedocs.io/en/latest/manual/deployment/[OSTree documentation]. Defaults to "poky". | 72 | * OSTREE_OSNAME - OS deployment name on your target device. For more information about deployments and osnames see the https://ostree.readthedocs.io/en/latest/manual/deployment/[OSTree documentation]. Defaults to "poky". |
73 | * OSTREE_INITRAMFS_IMAGE - initramfs/initrd image that is used as a proxy while booting into OSTree deployment. Do not change this setting unless you are sure that your initramfs can serve as such a proxy. | 73 | * OSTREE_INITRAMFS_IMAGE - initramfs/initrd image that is used as a proxy while booting into OSTree deployment. Do not change this setting unless you are sure that your initramfs can serve as such a proxy. |
74 | * OSTREE_PUSH_CREDENTIALS - when set, your ostree commit will be pushed to a remote repo as a bitbake step. This should be the path to a JSON credentials file in https://github.com/advancedtelematic/sota-tools#credentials[the format accepted by garage-push]. | 74 | * SOTA_PACKED_CREDENTIALS - when set, your ostree commit will be pushed to a remote repo as a bitbake step. This should be the path to a JSON credentials file in https://github.com/advancedtelematic/sota-tools#credentials[the format accepted by garage-push]. |
75 | 75 | ||
76 | == Usage | 76 | == Usage |
77 | 77 | ||
@@ -113,12 +113,12 @@ ostree pull agl-snapshot agl-ota | |||
113 | ostree admin deploy --os=agl agl-snapshot:agl-ota | 113 | ostree admin deploy --os=agl agl-snapshot:agl-ota |
114 | .... | 114 | .... |
115 | 115 | ||
116 | === SOTA tools | 116 | === garage-push |
117 | 117 | ||
118 | SOTA tools currently contains only one tool, garage-push, which lets you push the changes in OSTree repository generated by bitbake process. It communicates with an http server capable of querying files with HEAD requests and uploading them with POST requests. In particular, this can be used with http://www.atsgarage.com/[ATS Garage]. garage-push is used as follows: | 118 | The https://github.com/advancedtelematic/aktualizr[aktualizr repo] contains a tool, garage-push, which lets you push the changes in OSTree repository generated by bitbake process. It communicates with an http server capable of querying files with HEAD requests and uploading them with POST requests. In particular, this can be used with http://www.atsgarage.com/[ATS Garage]. garage-push is used as follows: |
119 | 119 | ||
120 | .... | 120 | .... |
121 | garage-push --repo=/path/to/ostree-repo --ref=mybranch --credentials=/path/to/credentials.json | 121 | garage-push --repo=/path/to/ostree-repo --ref=mybranch --credentials=/path/to/credentials.zip |
122 | .... | 122 | .... |
123 | 123 | ||
124 | You can set OSTREE_PUSH_CREDENTIALS in your local.conf to make your build results be automatically synchronized with a remote server. Credentials are stored in the JSON format described in the https://github.com/advancedtelematic/sota-tools#credentials[sota-tools README]. | 124 | You can set SOTA_PACKED_CREDENTIALS in your local.conf to make your build results be automatically synchronized with a remote server. Credentials are stored in the JSON format described in the https://github.com/advancedtelematic/aktualizr/blob/master/README.sotatools.adoc[garage-push README]. This JSON file can be optionally stored inside a zip file, although if it is stored this way, the JSON file must be named treehub.json. |
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index adcafe3..1f8e195 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
@@ -159,7 +159,7 @@ IMAGE_CMD_ostree () { | |||
159 | } | 159 | } |
160 | 160 | ||
161 | IMAGE_TYPEDEP_ostreepush = "ostree" | 161 | IMAGE_TYPEDEP_ostreepush = "ostree" |
162 | IMAGE_DEPENDS_ostreepush = "sota-tools-native:do_populate_sysroot" | 162 | IMAGE_DEPENDS_ostreepush = "aktualizr-native:do_populate_sysroot" |
163 | IMAGE_CMD_ostreepush () { | 163 | IMAGE_CMD_ostreepush () { |
164 | # Print warnings if credetials are not set or if the file has not been found. | 164 | # Print warnings if credetials are not set or if the file has not been found. |
165 | if [ -n "${SOTA_PACKED_CREDENTIALS}" ]; then | 165 | if [ -n "${SOTA_PACKED_CREDENTIALS}" ]; then |
diff --git a/recipes-sota/aktualizr/aktualizr-native_git.bb b/recipes-sota/aktualizr/aktualizr-native_git.bb index 59479fd..b89e9de 100644 --- a/recipes-sota/aktualizr/aktualizr-native_git.bb +++ b/recipes-sota/aktualizr/aktualizr-native_git.bb | |||
@@ -1,16 +1,18 @@ | |||
1 | require aktualizr_common.inc | 1 | require aktualizr_common.inc |
2 | 2 | ||
3 | DEPENDS = "boost-native openssl-native libarchive-native libsodium-native" | 3 | DEPENDS = "boost-native glib-2.0-native curl-native openssl-native libarchive-native libsodium-native" |
4 | 4 | ||
5 | inherit native | 5 | inherit native |
6 | 6 | ||
7 | EXTRA_OECMAKE = "-DWARNING_AS_ERROR=OFF -DCMAKE_BUILD_TYPE=Release -DBUILD_OSTREE=OFF -DAKTUALIZR_VERSION=${PV}" | 7 | EXTRA_OECMAKE = "-DWARNING_AS_ERROR=OFF -DCMAKE_BUILD_TYPE=Release -DBUILD_SOTA_TOOLS=ON -DBUILD_OSTREE=OFF -DAKTUALIZR_VERSION=${PV}" |
8 | 8 | ||
9 | do_install_append () { | 9 | do_install_append () { |
10 | rm ${D}${bindir}/aktualizr | 10 | rm ${D}${bindir}/aktualizr |
11 | rm ${D}${bindir}/aktualizr_cert_provider | 11 | rm ${D}${bindir}/aktualizr_cert_provider |
12 | rm ${D}${bindir}/garage-deploy | ||
12 | } | 13 | } |
13 | 14 | ||
14 | FILES_${PN} = " \ | 15 | FILES_${PN} = " \ |
15 | ${bindir}/aktualizr_implicit_writer \ | 16 | ${bindir}/aktualizr_implicit_writer \ |
17 | ${bindir}/garage-push \ | ||
16 | " | 18 | " |
diff --git a/recipes-sota/aktualizr/aktualizr_common.inc b/recipes-sota/aktualizr/aktualizr_common.inc index 7ed3614..79c5e37 100644 --- a/recipes-sota/aktualizr/aktualizr_common.inc +++ b/recipes-sota/aktualizr/aktualizr_common.inc | |||
@@ -11,7 +11,7 @@ PR = "7" | |||
11 | SRC_URI = " \ | 11 | SRC_URI = " \ |
12 | git://github.com/advancedtelematic/aktualizr;branch=${BRANCH} \ | 12 | git://github.com/advancedtelematic/aktualizr;branch=${BRANCH} \ |
13 | " | 13 | " |
14 | SRCREV = "59c276c1d4800d025594b53900ee964533695731" | 14 | SRCREV = "67c4f44c4136d16871726449502e3926098e8524" |
15 | BRANCH ?= "master" | 15 | BRANCH ?= "master" |
16 | 16 | ||
17 | S = "${WORKDIR}/git" | 17 | S = "${WORKDIR}/git" |
diff --git a/recipes-sota/sota-tools/sota-tools_git.bb b/recipes-sota/sota-tools/sota-tools_git.bb deleted file mode 100644 index 5403d9a..0000000 --- a/recipes-sota/sota-tools/sota-tools_git.bb +++ /dev/null | |||
@@ -1,24 +0,0 @@ | |||
1 | DESCRIPTION = "Utility to push data to a server" | ||
2 | LICENSE = "MPL-2.0" | ||
3 | |||
4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=65d26fcc2f35ea6a181ac777e42db1ea" | ||
5 | |||
6 | S = "${WORKDIR}/git" | ||
7 | |||
8 | SRC_URI = "gitsm://github.com/advancedtelematic/sota-tools.git;branch=master" | ||
9 | SRCREV = "216cb84db98e9b0f8c6c1c407f480c5dd0b3cf62" | ||
10 | |||
11 | inherit cmake | ||
12 | |||
13 | DEPENDS = "boost glib-2.0 curl libarchive" | ||
14 | |||
15 | BBCLASSEXTEND = "native" | ||
16 | |||
17 | FILES_${PN} = "${bindir}/garage-push" | ||
18 | |||
19 | EXTRA_OECMAKE = "-DWARNING_AS_ERROR=OFF" | ||
20 | |||
21 | do_install() { | ||
22 | install -d ${D}/${bindir} | ||
23 | install -m 755 garage-push ${D}/${bindir} | ||
24 | } | ||