Skip to content

Commit

Permalink
Merge branch 'main' into file-path-prefixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ryan-pratt committed Jan 22, 2025
2 parents 0e425c4 + fb1a8ad commit 7981ef0
Show file tree
Hide file tree
Showing 10 changed files with 47 additions and 33 deletions.
2 changes: 1 addition & 1 deletion openc3-cosmos-init/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ARG OPENC3_NAMESPACE=openc3inc
ARG OPENC3_TAG=latest
ARG OPENC3_NODE_IMAGE=openc3-node
ARG OPENC3_BASE_IMAGE=openc3-base
ARG OPENC3_MC_RELEASE=RELEASE.2024-11-21T17-21-54Z
ARG OPENC3_MC_RELEASE=RELEASE.2025-01-17T23-25-50Z

FROM ${OPENC3_DEPENDENCY_REGISTRY}/minio/mc:${OPENC3_MC_RELEASE} AS minio-mc
FROM ${OPENC3_REGISTRY}/${OPENC3_NAMESPACE}/${OPENC3_NODE_IMAGE}:${OPENC3_TAG} AS openc3-frontend-tmp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -669,6 +669,7 @@ i.v-icon.mdi-chevron-down {
.item.muuri-item-hidden {
z-index: 0;
}
/* Graph.vue 'width = width / 2.0 - 12' is based on the margin: 6px */
.item-content {
position: relative;
cursor: pointer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1109,9 +1109,10 @@ export default {
height = height / 2.0 + 10 // 5px padding top and bottom
}
}
let width = viewWidth - 68 // padding left and right
let width = viewWidth - 50 // padding left and right
if (!this.fullWidth) {
width = width / 2.0 - 10 // 5px padding left and right
// 6px padding left and right defined in TlmGrapher.vue .item-content
width = width / 2.0 - 12
}
return {
width: this.width || width,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# GNU Affero General Public License for more details.

# Modified by OpenC3, Inc.
# All changes Copyright 2024, OpenC3, Inc.
# All changes Copyright 2025, OpenC3, Inc.
# All Rights Reserved
#
# This file may also be used under the terms of a commercial license
Expand All @@ -36,9 +36,6 @@
<rux-progress :value="progress"></rux-progress>
</v-col>
</v-row>
<v-alert v-model="showAlert" closable :type="alertType">{{
alert
}}</v-alert>
<v-list
v-if="Object.keys(processes).length > 0"
class="list"
Expand Down Expand Up @@ -148,9 +145,6 @@ export default {
gems: [],
python: [],
processes: {},
alert: '',
alertType: 'success',
showAlert: false,
}
},
mounted() {
Expand All @@ -173,10 +167,11 @@ export default {
(response) => {
this.processes = response.data
if (Object.keys(this.processes).length > 0) {
// process_manager.rb script operates on a 5 second cycle
setTimeout(() => {
this.updateProcesses()
this.update()
}, 10000)
}, 2500)
}
},
)
Expand Down Expand Up @@ -212,42 +207,45 @@ export default {
})
Promise.all(promises)
.then((responses) => {
this.progress = 100
this.alert = `Uploaded ${responses.length} package${
responses.length > 1 ? 's' : ''
}`
this.alertType = 'success'
this.showAlert = true
this.$notify.normal({
body: `Uploaded ${responses.length} package${
responses.length > 1 ? 's' : ''
}`,
})
this.loadingPackage = false
this.files = []
setTimeout(() => {
this.showAlert = false
this.updateProcesses()
}, 5000)
this.update()
}, 2500)
})
.catch((error) => {
this.loadingPackage = false
})
}
},
deletePackage: function (pkg) {
deletePackage(pkg) {
this.$dialog
.confirm(`Are you sure you want to remove: ${pkg}`, {
okText: 'Delete',
cancelText: 'Cancel',
})
.then(function (dialog) {
.then((dialog) => {
return Api.delete(`/openc3-api/packages/${pkg}`)
})
.then((response) => {
this.alert = `Removed package ${pkg}`
this.alertType = 'success'
this.showAlert = true
this.$notify.normal({
body: `Removed package ${pkg}`,
})
setTimeout(() => {
this.showAlert = false
}, 5000)
this.update()
this.updateProcesses()
}, 2500)
})
// Error will probably never happen because we spawn the package removal
// and then wait for the response which happens in the background
.catch((error) => {
this.$notify.serious({
body: `Failed to remove package ${pkg}`,
})
})
},
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@
<v-card>
<v-card-title>Time Zone</v-card-title>
<v-card-subtitle>
The time zone to display for all COSMOS tools. (Note: All timestamps are
UTC in the backend).
The time zone to use in all COSMOS tools (graphs, time choosers, log
messages, etc). Anywhere a date / time is displayed, it will be in the
chosen time zone. (Note: All timestamps are UTC in the backend).
</v-card-subtitle>
<v-alert v-model="errorLoading" type="error" closable density="compact">
Error loading previous configuration due to {{ errorText }}
Expand Down
2 changes: 1 addition & 1 deletion openc3-minio/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ARG OPENC3_DEPENDENCY_REGISTRY=docker.io
# Consider updating openc3_build_ubi.sh when changing the release version
ARG OPENC3_MINIO_RELEASE=RELEASE.2024-12-18T13-15-44Z
ARG OPENC3_MINIO_RELEASE=RELEASE.2025-01-18T00-31-37Z
FROM ${OPENC3_DEPENDENCY_REGISTRY}/minio/minio:${OPENC3_MINIO_RELEASE}

COPY cacert.pem /devel/cacert.pem
Expand Down
2 changes: 1 addition & 1 deletion openc3/bin/pipinstall
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ else
echo "Command failed - retrying with --no-index"
pip3 install --no-index "$@"
if [ $? -eq 0 ]; then
echo "ERROR: pip install failed"
echo "ERROR: pip3 install failed"
fi
fi
10 changes: 10 additions & 0 deletions openc3/bin/pipuninstall
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/sh
python3 -m venv $PYTHONUSERBASE
source $PYTHONUSERBASE/bin/activate
echo "pip3 uninstall $@"
pip3 uninstall "$@"
if [ $? -eq 0 ]; then
echo "Command succeeded"
else
echo "ERROR: pip3 uninstall failed"
fi
3 changes: 2 additions & 1 deletion openc3/lib/openc3/models/python_package_model.rb
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ def self.install(name_or_path, scope:)
def self.destroy(name, scope:)
package_name, version = self.extract_name_and_version(name)
Logger.info "Uninstalling package: #{name}"
result = OpenC3::ProcessManager.instance.spawn(["pip", "uninstall", package_name, "-y"], "package_uninstall", name, Time.now + 3600.0, scope: scope)
pip_args = ["-y", package_name]
result = OpenC3::ProcessManager.instance.spawn(["/openc3/bin/pipuninstall"] + pip_args, "package_uninstall", name, Time.now + 3600.0, scope: scope)
return result.name
end

Expand Down
2 changes: 2 additions & 0 deletions scripts/linux/openc3_build_ubi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,8 @@ docker build \
cd ..

# openc3-cosmos-init
# NOTE: Ensure OPENC3_MC_RELEASE is on IronBank:
# https://ironbank.dso.mil/repomap/details;registry1Path=opensource%252Fminio%252Fmc
# NOTE: RELEASE.2023-10-14T01-57-03Z is the last MINIO/MC release to support UBI8
cd openc3-cosmos-init
docker build \
Expand Down

0 comments on commit 7981ef0

Please sign in to comment.