summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/build-workflow.yml4
-rw-r--r--.github/workflows/ci_pipeline.yml4
-rw-r--r--.github/workflows/hosted-post-merge_version_update.yml2
-rw-r--r--.github/workflows/pull-request-checks.yml48
-rw-r--r--.github/workflows/update-tedge-ref-docs.yml12
-rw-r--r--crates/common/certificate/src/lib.rs2
-rw-r--r--crates/common/download/examples/simple_download.rs4
-rw-r--r--crates/common/download/src/download.rs6
-rw-r--r--crates/common/flockfile/src/unix.rs25
-rw-r--r--crates/common/json_writer/src/lib.rs6
-rw-r--r--crates/common/logged_command/src/logged_command.rs3
-rw-r--r--crates/common/mqtt_channel/src/messages.rs2
-rw-r--r--crates/common/mqtt_channel/src/tests.rs4
-rw-r--r--crates/common/tedge_config/src/tedge_config_repository.rs4
-rw-r--r--crates/common/tedge_utils/src/file.rs14
-rw-r--r--crates/common/tedge_utils/src/fs.rs6
-rw-r--r--crates/common/tedge_utils/src/fs_notify.rs8
-rw-r--r--crates/core/agent_interface/src/error.rs2
-rw-r--r--crates/core/agent_interface/src/messages.rs24
-rw-r--r--crates/core/agent_interface/src/software.rs4
-rw-r--r--crates/core/agent_interface/src/topic.rs4
-rw-r--r--crates/core/c8y_api/src/http_proxy.rs5
-rw-r--r--crates/core/c8y_api/src/json_c8y.rs6
-rw-r--r--crates/core/c8y_smartrest/src/operations.rs4
-rw-r--r--crates/core/c8y_smartrest/src/smartrest_deserializer.rs22
-rw-r--r--crates/core/c8y_smartrest/src/smartrest_serializer.rs14
-rw-r--r--crates/core/c8y_smartrest/src/topic.rs4
-rw-r--r--crates/core/c8y_translator/src/json.rs2
-rw-r--r--crates/core/c8y_translator/src/serializer.rs2
-rw-r--r--crates/core/plugin_sm/src/operation_logs.rs4
-rw-r--r--crates/core/plugin_sm/tests/plugin.rs2
-rw-r--r--crates/core/tedge/src/cli/certificate/create.rs2
-rw-r--r--crates/core/tedge/src/cli/certificate/remove.rs2
-rw-r--r--crates/core/tedge/src/cli/certificate/show.rs2
-rw-r--r--crates/core/tedge/src/cli/config/commands/set.rs2
-rw-r--r--crates/core/tedge/src/cli/config/commands/unset.rs2
-rw-r--r--crates/core/tedge/src/cli/connect/bridge_config.rs2
-rw-r--r--crates/core/tedge/src/cli/connect/bridge_config_azure.rs2
-rw-r--r--crates/core/tedge/src/cli/connect/bridge_config_c8y.rs2
-rw-r--r--crates/core/tedge/src/cli/connect/c8y_direct_connection.rs2
-rw-r--r--crates/core/tedge/src/cli/connect/cli.rs2
-rw-r--r--crates/core/tedge/src/cli/connect/command.rs15
-rw-r--r--crates/core/tedge/src/cli/connect/common_mosquitto_config.rs4
-rw-r--r--crates/core/tedge/src/system_services/manager.rs2
-rw-r--r--crates/core/tedge/src/system_services/managers/config.rs4
-rw-r--r--crates/core/tedge_agent/src/agent.rs48
-rw-r--r--crates/core/tedge_agent/src/restart_operation_handler.rs2
-rw-r--r--crates/core/tedge_agent/src/state.rs12
-rw-r--r--crates/core/tedge_mapper/src/az/converter.rs4
-rw-r--r--crates/core/tedge_mapper/src/c8y/converter.rs37
-rw-r--r--crates/core/tedge_mapper/src/c8y/mapper.rs2
-rw-r--r--crates/core/tedge_mapper/src/c8y/tests.rs2
-rw-r--r--crates/core/tedge_mapper/src/c8y/topic.rs4
-rw-r--r--crates/core/thin_edge_json/src/alarm.rs6
-rw-r--r--crates/core/thin_edge_json/src/event.rs4
-rw-r--r--crates/core/thin_edge_json/src/measurement.rs6
-rw-r--r--crates/core/thin_edge_json/src/parser.rs19
-rw-r--r--crates/core/thin_edge_json/src/serialize.rs2
-rw-r--r--crates/tests/sawtooth_publisher/src/main.rs4
-rw-r--r--crates/tests/tedge_test_utils/src/fs.rs2
-rw-r--r--docs/src/howto-guides/002_installation.md9
-rw-r--r--docs/src/tutorials/raise-alarm.md8
-rw-r--r--plugins/c8y_configuration_plugin/src/config.rs4
-rw-r--r--plugins/c8y_configuration_plugin/src/download.rs18
-rw-r--r--plugins/c8y_configuration_plugin/src/main.rs8
-rw-r--r--plugins/c8y_configuration_plugin/src/upload.rs6
-rw-r--r--plugins/c8y_log_plugin/src/config.rs2
-rw-r--r--plugins/c8y_log_plugin/src/logfile_request.rs10
-rw-r--r--plugins/c8y_log_plugin/src/main.rs14
-rw-r--r--plugins/tedge_apt_plugin/src/error.rs15
-rw-r--r--plugins/tedge_apt_plugin/src/main.rs19
-rw-r--r--plugins/tedge_apt_plugin/src/module_check.rs64
-rwxr-xr-xuninstall-thin-edge_io.sh2
73 files changed, 337 insertions, 294 deletions
diff --git a/.github/workflows/build-workflow.yml b/.github/workflows/build-workflow.yml
index d45936bd..f1ff16aa 100644
--- a/.github/workflows/build-workflow.yml
+++ b/.github/workflows/build-workflow.yml
@@ -19,7 +19,7 @@ jobs:
uses: actions/checkout@v3
- name: Enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
- name: Enable cache
# https://github.com/marketplace/actions/rust-cache
@@ -55,7 +55,7 @@ jobs:
uses: actions/checkout@v3
- name: Enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
with:
targets: ${{ matrix.target }}
diff --git a/.github/workflows/ci_pipeline.yml b/.github/workflows/ci_pipeline.yml
index da164d16..b5265197 100644
--- a/.github/workflows/ci_pipeline.yml
+++ b/.github/workflows/ci_pipeline.yml
@@ -26,7 +26,7 @@ jobs:
uses: actions/checkout@v3
- name: Enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
- name: Enable cache
# https://github.com/marketplace/actions/rust-cache
@@ -88,7 +88,7 @@ jobs:
uses: actions/checkout@v3
- name: Enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
with:
targets: ${{ matrix.target }}
diff --git a/.github/workflows/hosted-post-merge_version_update.yml b/.github/workflows/hosted-post-merge_version_update.yml
index af90319a..48430697 100644
--- a/.github/workflows/hosted-post-merge_version_update.yml
+++ b/.github/workflows/hosted-post-merge_version_update.yml
@@ -20,7 +20,7 @@ jobs:
- name: enable toolchain via github action
uses: actions-rs/toolchain@v1
with:
- toolchain: 1.58.1
+ toolchain: 1.63.0
components: cargo
override: true
diff --git a/.github/workflows/pull-request-checks.yml b/.github/workflows/pull-request-checks.yml
index 49080505..e69fb710 100644
--- a/.github/workflows/pull-request-checks.yml
+++ b/.github/workflows/pull-request-checks.yml
@@ -44,6 +44,36 @@ jobs:
workflows:
- '.github/workflows/**'
+ #
+ # Checking that Cargo.lock is up to date
+ #
+ check-lockfile-uptodate:
+ name: Check whether Cargo.lock is up to date
+ runs-on: ubuntu-20.04
+ outputs:
+ locks: ${{ steps.filter.outputs.locks }}
+ steps:
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@1.58.1
+ with:
+ targets: armv7-unknown-linux-gnueabihf
+
+ - uses: Swatinem/rust-cache@v1
+
+ - uses: dorny/paths-filter@v2
+ id: filter
+ with:
+ filters: |
+ locks:
+ - '**/Cargo.toml'
+
+ - name: Check whether lockfile is up to date
+ if: steps.filter.outputs.locks == 'true'
+ uses: actions-rs/cargo@v1
+ with:
+ command: check
+ args: --locked
+
udeps:
name: Check for unused dependencies
runs-on: ubuntu-latest
@@ -138,7 +168,7 @@ jobs:
uses: actions/checkout@v3
- name: enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
with:
components: rustfmt, clippy
@@ -150,7 +180,7 @@ jobs:
uses: actions-rs/cargo@v1
# https://github.com/marketplace/actions/rust-cargo
with:
- toolchain: 1.58.1
+ toolchain: 1.63.0
command: clippy
args: --version
@@ -158,7 +188,7 @@ jobs:
uses: actions-rs/cargo@v1
# https://github.com/marketplace/actions/rust-cargo
with:
- toolchain: 1.58.1
+ toolchain: 1.63.0
command: clippy
args: --all-features
@@ -190,7 +220,7 @@ jobs:
uses: actions/checkout@v3
- name: enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
- name: Enable cache
# https://github.com/marketplace/actions/rust-cache
@@ -228,7 +258,7 @@ jobs:
uses: actions/checkout@v3
- name: enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
- name: Enable cache
# https://github.com/marketplace/actions/rust-cache
@@ -259,7 +289,7 @@ jobs:
uses: actions/checkout@v3
- name: enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
with:
targets: armv7-unknown-linux-gnueabihf
@@ -287,7 +317,7 @@ jobs:
uses: actions/checkout@v3
- name: enable toolchain via github action
- uses: dtolnay/rust-toolchain@1.58.1
+ uses: dtolnay/rust-toolchain@1.63.0
with:
target: armv7-unknown-linux-gnueabihf
@@ -312,8 +342,8 @@ jobs:
# - name: Checkout
# uses: actions/checkout@v3
#
-# - name: Install rust v1.58.1
-# uses: dtolnay/rust-toolchain@1.58.1
+# - name: Install rust v1.63.0
+# uses: dtolnay/rust-toolchain@1.63.0
#
# - name: Enable cache
# # https://github.com/marketplace/actions/rust-cache
diff --git a/.github/workflows/update-tedge-ref-docs.yml b/.github/workflows/update-tedge-ref-docs.yml
index 2f37f29e..a644339c 100644
--- a/.github/workflows/update-tedge-ref-docs.yml
+++ b/.github/workflows/update-tedge-ref-docs.yml
@@ -6,36 +6,36 @@ on:
# runs automatically on 00:00 UTC on 1st of every month
schedule:
- cron: "0 0 1 * *"
-
+
jobs:
build-tedge-create-ref-docs:
runs-on: Ubuntu-20.04
-
+
steps:
- name: Checkout
uses: actions/checkout@v3
- run: |
git config --global user.email "info@thin-edge.io"
git config --global user.name "Versioneer"
-
+
- name: enable toolchain via github action
# https://github.com/actions-rs/toolchain
uses: actions-rs/toolchain@v1
with:
- toolchain: 1.58.1
+ toolchain: 1.63.0
override: true
- name: Enable cache
# https://github.com/marketplace/actions/rust-cache
uses: Swatinem/rust-cache@v1
-
+
- name: Build tedge
uses: actions-rs/cargo@v1
# https://github.com/marketplace/actions/rust-cargo
with:
command: build
args: --release -p tedge
-
+
- name: run the update script
run: ./docs/gen-ref-docs.sh
- name: Create Pull Request
diff --git a/crates/common/certificate/src/lib.rs b/crates/common/certificate/src/lib.rs
index 0c81a73d..ecfbd88a 100644
--- a/crates/common/certificate/src/lib.rs
+++ b/crates/common/certificate/src/lib.rs
@@ -110,7 +110,7 @@ impl KeyCertPair {
id: &str,
not_before: OffsetDateTime,
) -> Result<KeyCertPair, CertificateError> {
- let () = KeyCertPair::check_identifier(id, config.max_cn_size)?;
+ KeyCertPair::check_identifier(id, config.max_cn_size)?;
let mut distinguished_name = rcgen::DistinguishedName::new();
distinguished_name.push(rcgen::DnType::CommonName, id);
distinguished_name.push(rcgen::DnType::OrganizationName, &config.organization_name);
diff --git a/crates/common/download/examples/simple_download.rs b/crates/common/download/examples/simple_download.rs
index e583b0eb..763a91c0 100644
--- a/crates/common/download/examples/simple_download.