Skip to content

Commit

Permalink
revert to test
Browse files Browse the repository at this point in the history
  • Loading branch information
elvece committed Jan 29, 2025
1 parent b2840c6 commit 463a827
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 8 deletions.
10 changes: 5 additions & 5 deletions container-runtime/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 23 additions & 3 deletions container-runtime/src/Adapters/Systems/SystemForEmbassy/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -701,11 +701,11 @@ export class SystemForEmbassy implements System {
path: EMBASSY_DEPENDS_ON_PATH_PREFIX,
})) as Record<string, readonly string[]>

const dependsOn: Record<string, readonly string[]> = storedDependsOn ? storedDependsOn : {
const dependsOn: Record<string, readonly string[] | null> = storedDependsOn ? storedDependsOn : {
...Object.fromEntries(
Object.entries(this.manifest.dependencies || {})?.filter(x => x[1].requirement.type === "required").map((x) => [
Object.entries(this.manifest.dependencies || {})?.map((x) => [
x[0],
[],
null,
]) || [],
),
...rawDepends,
Expand All @@ -721,6 +721,26 @@ export class SystemForEmbassy implements System {
([key, value]): T.Dependencies => {
const dependency = this.manifest.dependencies?.[key]
if (!dependency) return []
if (value == null) {
const versionRange = dependency.version
if (dependency.requirement.type === "required") {
return [
{
id: key,
versionRange,
kind: "running",
healthChecks: [],
},
]
}
return [
{
kind: "exists",
id: key,
versionRange,
},
]
}
const versionRange = dependency.version
const kind = "running"
return [
Expand Down

0 comments on commit 463a827

Please sign in to comment.