Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • beat.cmdline beat.cmdline
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 22
    • Issues 22
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • beatbeat
  • beat.cmdlinebeat.cmdline
  • Issues
  • #21
Closed
Open
Issue created Apr 12, 2018 by Jaden DIEFENBAUGH@jdiefenbaughContributor

Add local environment querying support

(This is the first part of beat.editor#77 (closed))

Right now beat.core can tell us about the available local environments available (see dock.py). The goal is to give beat.editor access to this info, which means that beat.cmdline needs a nice way to supply this info.

I'd add a new beat sub-app, environment (with an env shortcut) with a list command that would give the necessary info. Ideally the environment info would be provided in some machine-parseable format and provide at least:

  • environment names & versions
  • queues for each environment along with their slot counts
  • the environments' packages (names & versions)

Right now I'm thinking to just use JSON of the same format as the beat.web endpoint for environments. BEAT staging example:

[
  {
    "name": "Scientific Python 2.7",
    "queues": {
      "Default": {
        "memory_limit": 5983,
        "nb_slots": 2,
        "max_slots_per_user": 2,
        "nb_cores_per_slot": 1,
        "time_limit": 360
      }
    },
    "accessibility": "public",
    "languages": [
      "python"
    ],
    "version": "0.0.4",
    "short_description": "Scientific Python 2.7"
  },
  {
    "name": "Scientific Python 2.7",
    "queues": {
      "Default": {
        "memory_limit": 5983,
        "nb_slots": 2,
        "max_slots_per_user": 2,
        "nb_cores_per_slot": 1,
        "time_limit": 360
      }
    },
    "accessibility": "public",
    "languages": [
      "python"
    ],
    "version": "1.0.0",
    "short_description": "Scientific Python 2.7"
  }
]

The one thing missing is the package info. There would be a "packages" field added to each environment that points to a dict consisting of package names for keys and versions for values:

[
  {
    "name": "Scientific Python 2.7",
    "packages": {
        "alabaster": "0.7.6",
        "babel": "1.3",
        ...
    },
    "queues": {
      "Default": {
        "memory_limit": 5983,
        "nb_slots": 2,
        "max_slots_per_user": 2,
        "nb_cores_per_slot": 1,
        "time_limit": 360
      }
    },
    "accessibility": "public",
    "languages": [
      "python"
    ],
    "version": "0.0.4",
    "short_description": "Scientific Python 2.7"
  },
  {
    "name": "Scientific Python 2.7",
    "packages": {
        "alabaster": "0.7.10",
        "Babel": "2.4.0",
        ...
    },
    "queues": {
      "Default": {
        "memory_limit": 5983,
        "nb_slots": 2,
        "max_slots_per_user": 2,
        "nb_cores_per_slot": 1,
        "time_limit": 360
      }
    },
    "accessibility": "public",
    "languages": [
      "python"
    ],
    "version": "1.0.0",
    "short_description": "Scientific Python 2.7"
  }
]

This is the same extension proposed in beat.web#495 (closed).

Assignee
Assign to
Time tracking