Skip to content

Commit

Permalink
[api] Fix get versions
Browse files Browse the repository at this point in the history
  • Loading branch information
Samuel Hassine committed Mar 3, 2022
1 parent d3cf0c6 commit 78e2e18
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ Retrieve the application information version add dependencies
"""
type AppInfo {
"""
The OpenCTI aplication version
The OpenCTI application version
"""
version: String!
"""
Expand Down
3 changes: 2 additions & 1 deletion opencti-platform/opencti-graphql/src/config/conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {
ABSTRACT_STIX_DOMAIN_OBJECT,
} from '../schema/general';
import { STIX_SIGHTING_RELATIONSHIP } from '../schema/stixSightingRelationship';
import pjson from '../../package.json';

// https://golang.org/src/crypto/x509/root_linux.go
const LINUX_CERTFILES = [
Expand Down Expand Up @@ -115,7 +116,7 @@ export const BUS_TOPICS = {
},
};

export const PLATFORM_VERSION = process.env.npm_package_version;
export const PLATFORM_VERSION = pjson.version;

export const booleanConf = (key, defaultValue = true) => {
const configValue = nconf.get(key);
Expand Down
2 changes: 1 addition & 1 deletion opencti-platform/opencti-graphql/src/generated/graphql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export type AppInfo = {
dependencies: Array<DependencyVersion>;
/** The OpenCTI api current memory usage */
memory?: Maybe<AppMemory>;
/** The OpenCTI aplication version */
/** The OpenCTI application version */
version: Scalars['String'];
};

Expand Down

0 comments on commit 78e2e18

Please sign in to comment.