Skip to content

Commit 4641f87

Browse files
authored
Merge pull request #2036 from OpenC3/cosmos-core
COSMOS Core and COSMOS Enterprise terminology
2 parents 0f7afad + 759ae0a commit 4641f87

File tree

177 files changed

+303
-289
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

177 files changed

+303
-289
lines changed

docs.openc3.com/docs/configuration/plugins.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ The VARIABLE keyword defines a variable that will be requested for the user to e
6161
## NEEDS_DEPENDENCIES
6262
<div class="right">(Since 5.5.0)</div>**Indicates the plugin needs dependencies and sets the GEM_HOME environment variable**
6363

64-
If the plugin has a top level lib folder or lists runtime dependencies in the gemspec, NEEDS_DEPENDENCIES is effectively already set. Note that in Enterprise Edition, having NEEDS_DEPENDENCIES adds the NFS volume mount to the Kubernetes pod.
64+
If the plugin has a top level lib folder or lists runtime dependencies in the gemspec, NEEDS_DEPENDENCIES is effectively already set. Note that in Enterprise, having NEEDS_DEPENDENCIES adds the NFS volume mount to the Kubernetes pod.
6565

6666

6767
## INTERFACE
@@ -311,7 +311,7 @@ CMD python interface_microservice.py DEFAULT__INTERFACE__INT1
311311
### CONTAINER
312312
<div class="right">(Since 5.7.0)</div>**Docker Container**
313313

314-
Container to execute and run the microservice in. Only used in COSMOS Enterprise Edition.
314+
Container to execute and run the microservice in. Only used in COSMOS Enterprise.
315315

316316
| Parameter | Description | Required |
317317
|-----------|-------------|----------|
@@ -693,7 +693,7 @@ Generic key/value(s) options to pass to the microservice. These take the form of
693693
### CONTAINER
694694
**Docker Container**
695695

696-
Container to execute and run the microservice in. Only used in COSMOS Enterprise Edition.
696+
Container to execute and run the microservice in. Only used in COSMOS Enterprise.
697697

698698
| Parameter | Description | Required |
699699
|-----------|-------------|----------|
@@ -839,7 +839,7 @@ Whether or not the tool is shown in the Navigation menu. Should generally be tru
839839
### POSITION
840840
<div class="right">(Since 5.0.8)</div>**Position of the tool in the nav bar**
841841

842-
Position of the tool starting at 2 (1 is reserved for Admin Console). Tools without a position are appended to the end as they are installed. All COSMOS open source tools have consecutive integer values for position.
842+
Position of the tool starting at 2 (1 is reserved for Admin Console). Tools without a position are appended to the end as they are installed. All COSMOS Core tools have consecutive integer values for position.
843843

844844
| Parameter | Description | Required |
845845
|-----------|-------------|----------|

docs.openc3.com/docs/configuration/protocols.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ The Ignore Packet protocol drops specified command packets sent by COSMOS or dro
282282

283283
## Custom Protocols
284284

285-
Creating a custom protocol is easy and should be the default solution for customizing COSMOS Interfaces (rather than creating a new Interface class). However, creating custom Interfaces is still useful for defaulting parameters to values that always are fixed for your target and for including the necessary Protocols. The base COSMOS Interfaces take a lot of parameters that can be confusing to your end users. Thus you may want to create a custom Interface just to hard coded these values and cut the available parameters down to something like the hostname and port to connect to.
285+
Creating a custom protocol is easy and should be the default solution for customizing COSMOS Interfaces (rather than creating a new Interface class). However, creating custom Interfaces is still useful for defaulting parameters to values that always are fixed for your target and for including the necessary Protocols. The COSMOS Interfaces take a lot of parameters that can be confusing to your end users. Thus you may want to create a custom Interface just to hard coded these values and cut the available parameters down to something like the hostname and port to connect to.
286286

287287
All custom Protocols should derive from the Protocol class [openc3/interfaces/protocols/protocol.rb](https://github.com/OpenC3/cosmos/blob/main/openc3/lib/openc3/interfaces/protocols/protocol.rb) (Ruby) and [openc3/interfaces/protocols/protocol.py](https://github.com/OpenC3/cosmos/blob/main/openc3/python/openc3/interfaces/protocols/protocol.py) (Python). This class defines the 9 methods that are relevant to writing your own protocol. The base class implementation for each method is included below as well as a discussion as to how the methods should be overridden and used in your own Protocols.
288288

docs.openc3.com/docs/development/curl.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ This information is just generally used behind the scenes in COSMOS tools
1111

1212
The COSMOS APIs are all served over HTTP, which means you can use curl to experiment with them. Curl is a great tool for seeing exactly how the API responds to any given request.
1313

14-
## Curl Example with OpenC3 COSMOS Open Source
14+
## Curl Example with OpenC3 COSMOS Core
1515

16-
OpenC3 COSMOS Open Source just has a single user account, so all you need to do is pass the single password as the token with your requests like this.
16+
OpenC3 COSMOS Core just has a single user account, so all you need to do is pass the single password as the token with your requests like this.
1717

1818
Request:
1919

docs.openc3.com/docs/development/developing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ sidebar_custom_props:
77

88
# Developing COSMOS
99

10-
So you want to help develop COSMOS? All of our open source COSMOS code is on [Github](https://github.com/) so the first thing to do is get an [account](https://github.com/join). Next [clone](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) the [COSMOS](https://github.com/openc3/cosmos) repository. We accept contributions from others as [Pull Requests](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests).
10+
So you want to help develop COSMOS? All of our COSMOS Core code is on [Github](https://github.com/) so the first thing to do is get an [account](https://github.com/join). Next [clone](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) the [COSMOS](https://github.com/openc3/cosmos) repository. We accept contributions from others as [Pull Requests](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests).
1111

1212
## Development Tools
1313

docs.openc3.com/docs/getting-started/cli.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ irb(main):002:0> Cosmos::Api::WHITELIST
6868
6969
## Script
7070
71-
The script methods allow you to list the available scripts, spawn a script, and run a script while monitoring its output. Note that you must set the OPENC3_API_PASSWORD in Open Source and both the OPENC3_API_USER and OPENC3_API_PASSWORD in Enterprise.
71+
The script methods allow you to list the available scripts, spawn a script, and run a script while monitoring its output. Note that you must set the OPENC3_API_PASSWORD in COSMOS Core and both the OPENC3_API_USER and OPENC3_API_PASSWORD in COSMOS Enterprise.
7272
7373
:::note Offline Access Token
7474
You must visit the frontend Script Runner page as the OPENC3_API_USER or run "openc3.sh cli script init" in order to obtain an offline access token before the other script cli methods will work.

docs.openc3.com/docs/getting-started/generators.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ This creates the following files:
3737
| Name | Description |
3838
| ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
3939
| .gitignore | Tells git to ignore any node_modules directory (for tool development) |
40-
| LICENSE.txt | License for the plugin. COSMOS Plugins should be licensed in a manner compatible with the AGPLv3, unless they are designed only for use with COSMOS Enterprise Edition. |
40+
| LICENSE.txt | License for the plugin. COSMOS Plugins should be licensed in a manner compatible with the AGPLv3, unless they are designed only for use with COSMOS Enterprise. |
4141
| openc3-cosmos-gse.gemspec | Gemspec file which should be edited to add user specific information like description, authors, emails, homepage, etc. The name of this file is used in compiling the plugin contents into the final corresponding gem file: e.g. openc3-cosmos-gse-1.0.0.gem. COSMOS plugins should always begin with the openc3-cosmos prefix to make them easily identifiable in the Rubygems repository. The file is formatted as documented at: https://guides.rubygems.org/specification-reference/ |
4242
| plugin.txt | COSMOS specific file for Plugin creation. Learn more [here](../configuration/plugins). |
4343
| Rakefile | Ruby Rakefile configured to support building the plugin by running "openc3.sh cli rake build VERSION=X.X.X" where X.X.X is the plugin version number |

docs.openc3.com/docs/getting-started/key-concepts.md

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,32 +18,41 @@ The main COSMOS [repo](https://github.com/OpenC3/cosmos) contains all the source
1818

1919
Per [Docker](https://docs.docker.com/get-started/overview/#images), "An image is a read-only template with instructions for creating a Docker container." The base operating system COSMOS uses is called [Alpine Linux](https://www.alpinelinux.org/). It is a simple and compact image with a full package system that allows us to install our dependencies. Starting with Alpine, we create a [Dockerfile](https://docs.docker.com/engine/reference/builder/) to add Ruby and Python and a few other packages to create our own docker image. We further build upon that image to create a NodeJS image to support our frontend and additional images to support our backend.
2020

21+
The following diagram shows all the COSMOS Core and Enterprise container images. Images are built from the bottom up in the Dockerfile using [FROM](https://docs.docker.com/reference/dockerfile/#from). Images referenced with "Uses" are used during the build stage.
22+
23+
![COSMOS Images](/img/cosmos-images.png)
24+
2125
### Containers
2226

2327
Per [Docker](https://www.docker.com/resources/what-container/), "a container is a standard unit of software that packages up code and all its dependencies so the application runs quickly and reliably from one computing environment to another." Also per [Docker](https://docs.docker.com/guides/walkthroughs/what-is-a-container/), "A container is an isolated environment for your code. This means that a container has no knowledge of your operating system, or your files. It runs on the environment provided to you by Docker Desktop. Containers have everything that your code needs in order to run, down to a base operating system." COSMOS utilizes containers to provide a consistent runtime environment. Containers make it easy to deploy to local on-prem servers, cloud environments, or air-gapped networks.
2428

25-
The COSMOS Open Source containers consist of the following:
29+
The COSMOS Core containers consist of the following:
2630

2731
| Name | Description |
2832
| ---------------------------------------- | ------------------------------------------------------------------------------------------------------ |
29-
| cosmos-openc3-cosmos-init-1 | Copies files to Minio and configures COSMOS then exits |
33+
| cosmos-openc3-cosmos-init-1 | Run migrations, installs the COSMOS tools, and then exits |
3034
| cosmos-openc3-operator-1 | Main COSMOS container that runs the interfaces and target microservices |
35+
| cosmos-openc3-traefik-1 | Provides a reverse proxy and load balancer with routes to the COSMOS endpoints |
3136
| cosmos-openc3-cosmos-cmd-tlm-api-1 | Rails server that provides all the COSMOS API endpoints |
3237
| cosmos-openc3-cosmos-script-runner-api-1 | Rails server that provides the Script API endpoints |
33-
| cosmos-openc3-redis-1 | Serves the static target configuration |
34-
| cosmos-openc3-redis-ephemeral-1 | Serves the [streams](https://redis.io/docs/data-types/streams) containing the raw and decomutated data |
3538
| cosmos-openc3-minio-1 | Provides a S3 like bucket storage interface and also serves as a static webserver for the tool files |
36-
| cosmos-openc3-traefik-1 | Provides a reverse proxy and load balancer with routes to the COSMOS endpoints |
39+
| cosmos-openc3-redis-1 | Serves the static target configuration and Current Value Table |
40+
| cosmos-openc3-redis-ephemeral-1 | Serves the [streams](https://redis.io/docs/data-types/streams) containing the raw and decomutated data |
3741

3842
The container list for [Enterprise COSMOS](https://openc3.com/enterprise) consists of the following:
3943

4044
| Name | Description |
4145
| ------------------------------------- | --------------------------------------------------------------------------------------------- |
46+
| cosmos-enterprise-openc3-grafana-1 | [Grafana](https://grafana.com/) container preconfigured with the COSMOS Data Source |
4247
| cosmos-enterprise-openc3-metrics-1 | Rails server that provides metrics on COSMOS performance |
4348
| cosmos-enterprise-openc3-keycloak-1 | Single-Sign On service for authentication |
4449
| cosmos-enterprise-openc3-postgresql-1 | SQL Database for use by Keycloak |
4550
| openc3-nfs \* | Network File System pod only for use in Kubernetes to share code libraries between containers |
4651

52+
A diagram of the running containers is shown below:
53+
54+
![COSMOS Images](/img/cosmos-containers.png)
55+
4756
### Docker Compose
4857

4958
Per [Docker](https://docs.docker.com/compose/), "Compose is a tool for defining and running multi-container Docker applications. With Compose, you use a YAML file to configure your application's services. Then, with a single command, you create and start all the services from your configuration." OpenC3 uses compose files to both build and run COSMOS. The [compose.yaml](https://github.com/OpenC3/cosmos-project/blob/main/compose.yaml) is where ports are exposed and environment variables are used.

docs.openc3.com/docs/guides/exposing-microservices.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ MICROSERVICE CFDP <%= cfdp_microservice_name %>
5555

5656
Leaving the variables at their default values the following will occur:
5757

58-
- The microservice will be exposed internally to Docker (Open Source or Enterprise) at: `http://openc3-operator:2905`
58+
- The microservice will be exposed internally to Docker (Core or Enterprise) at: `http://openc3-operator:2905`
5959
- The microservice will be exposed internally to Kubernetes (Enterprise) at: `http://default-user-cfdp-service:2905`
6060
- The microservice will be exposed externally to the network at: `http://localhost:2900/cfdp`
6161

@@ -73,7 +73,7 @@ INTERFACE <%= my_interface_name %> http_server_interface.rb <%= my_port %>
7373
PORT <%= my_port %>
7474
```
7575

76-
- The interface will be exposed internally to Docker (Open Source or Enterprise) at: `http://openc3-operator:2910`
76+
- The interface will be exposed internally to Docker (Core or Enterprise) at: `http://openc3-operator:2910`
7777
- The interface will be exposed internally to Kubernetes (Enterprise) at: `http://default-interface-my-int-service:2905`
7878
- The interface will be exposed externally to the network at: `http://localhost:2900/myint`
7979

@@ -86,7 +86,7 @@ The sharded operator is expected to be used on Kubernetes whenever the Kubernete
8686

8787
Sometimes you might want to have an INTERFACE connect to a microservice you are running. For this case, only the PORT keyword is required on the INTERFACE or MICROSERVICE because we are only connecting internally and ROUTE_PREFIX isn't used.
8888

89-
The following code taken from our demo plugin provides an example of how to calculate the correct hostname across both Open Source and Enterprise versions of COSMOS in a plugin.txt file:
89+
The following code taken from our demo plugin provides an example of how to calculate the correct hostname across both Core and Enterprise versions of COSMOS in a plugin.txt file:
9090

9191
```
9292
<% example_host = ENV['KUBERNETES_SERVICE_HOST'] ? "#{scope}-user-#{example_microservice_name.downcase.gsub('__', '-').gsub('_', '-')}-service" : "openc3-operator" %>

0 commit comments

Comments
 (0)