GithubHelp home page GithubHelp logo

rasahq / rasactl Goto Github PK

View Code? Open in Web Editor NEW
15.0 5.0 5.0 3 MB

rasactl deploys Rasa X / Enterprise on your local or remote Kubernetes cluster and manages Rasa X / Enterprise deployments.

Home Page: https://rasa.com

License: Apache License 2.0

Makefile 0.44% Go 99.25% Shell 0.25% Dockerfile 0.06%
rasa rasa-x rasa-enterprise kubernetes kind helm deployment cicd

rasactl's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

rasactl's Issues

rasactl open fails when there is no browser

Describe the bug
rasactl open fails when there is no browser

$ rasactl open
Error: Can't open the URL http://127.0.0.1:4321 in your web browser: exec: "xdg-open,x-www-browser,www-browser": executable file not found in $PATH
...

**Expected behaviour **

$ rasactl open
http://127.0.0.1:4321
...

rasactl version

  • rasactl --version

Add a `--background` option to `rasactl connect rasa`

rasactl connect rasa starts a rasa server in the foreground, so if you close the terminal, your server dies.
Would be helpful to have a --background flag so rasactl connect rasa --background starts a rasa server in the background independent of terminal session.

Emit notification if a newer version is available.

What problem are you trying to solve?

Print a notification that informs a newer version is available.

What's your suggested solution?

No response

Examples (if relevant)

No response

Is anything blocking this from being implemented? (if relevant)

No response

Definition of Done

No response

Model training lasts forever over Rasa X UI

Describe the bug
If you connect a Rasa OSS to Rasa X using the connect rasa command, model training triggered via Rasa UI X lasts forever. It is caused by an incorrect URL that is used by Rasa OSS to send results back.

Error encountered while uploading a model

Describe the bug
When uploading a trained model from Rasa X UI, I get "Upload failed" with the following error in the logs:

[2022-01-23 08:06:21 +0000] [24] [ERROR] Exception occurred while handling uri: 'http://x.x.x.x/api/projects/default/models'
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/connector.py", line 999, in _create_direct_connection
    hosts = await asyncio.shield(host_resolved)
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/connector.py", line 865, in _resolve_host
    addrs = await self._resolver.resolve(host, port, family=self._family)
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/resolver.py", line 31, in resolve
    infos = await self._loop.getaddrinfo(
  File "uvloop/loop.pyx", line 1469, in getaddrinfo
socket.gaierror: [Errno -2] Name or service not known

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/local/lib/python3.8/dist-packages/sanic/app.py", line 973, in handle_request
    response = await response
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/decorators.py", line 247, in decorated_function
    return await await_and_return_response(args, kwargs, request)
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/decorators.py", line 177, in await_and_return_response
    response = await response
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/decorators.py", line 84, in decorated_function
    return await f(request, user=user, *args, **kwargs)
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/blueprints/models.py", line 69, in upload_model
    minimum_version = await model_service.minimum_compatible_version()
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/services/model_service.py", line 182, in minimum_compatible_version
    info = await stack_service.version()
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/services/stack_service.py", line 124, in version
    response = await session.get(
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/client.py", line 520, in _request
    conn = await self._connector.connect(
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/connector.py", line 535, in connect
    proto = await self._create_connection(req, traces, timeout)
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/connector.py", line 892, in _create_connection
    _, proto = await self._create_direct_connection(req, traces, timeout)
  File "/usr/local/lib/python3.8/dist-packages/aiohttp/connector.py", line 1011, in _create_direct_connection
    raise ClientConnectorError(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway.docker.internal:5005 ssl:default [Name or service not known]

Uploading a model with rasactl model upload also fails with the following error:

Error: rasa server is not connected to the production environment

To Reproduce
Steps to reproduce the behavior:

  1. Install Rasa X following the docs here.
  2. Install rasa with pip install rasa.
  3. Create new project with rasa init and cd to the project.
  4. Upload the model from the UI or using rasactl model upload

Desktop (please complete the following information):

  • OS: Ubuntu 20.04

rasactl version*
rasactl version 1.0.1

Cannot connect to a local rasa open source server

Describe the bug

I get the following error message when running rasactl connect rasa.

panic: interface conversion: interface {} is nil, not map[string]interface {}

goroutine 1 [running]:
github.com/RasaHQ/rasactl/pkg/k8s.(*Kubernetes).GetRabbitMqCreds(0xc0004a6500)
        /go/src/rasactl/pkg/k8s/secrets.go:127 +0x23a
github.com/RasaHQ/rasactl/pkg/rasactl.(*RasaCtl).saveRasaEndpointsFile(0xc0004a6280, {0xc0010fe840, 0x20})
        /go/src/rasactl/pkg/rasactl/connect_rasa.go:280 +0x12b
github.com/RasaHQ/rasactl/pkg/rasactl.(*RasaCtl).ConnectRasa(0xc0004a6280)
        /go/src/rasactl/pkg/rasactl/connect_rasa.go:142 +0xdc9
github.com/RasaHQ/rasactl/cmd.connectRasaCmd.func2(0xc00029bb80, {0xc0000b8d20, 0x1, 0x3})
        /go/src/rasactl/cmd/connect_rasa.go:117 +0xab
github.com/spf13/cobra.(*Command).execute(0xc00029bb80, {0xc0000b8c90, 0x3, 0x3})
        /go/pkg/mod/github.com/spf13/[email protected]/command.go:856 +0x60e
github.com/spf13/cobra.(*Command).ExecuteC(0x3eff7e0)
        /go/pkg/mod/github.com/spf13/[email protected]/command.go:974 +0x3bc
github.com/spf13/cobra.(*Command).Execute(...)
        /go/pkg/mod/github.com/spf13/[email protected]/command.go:902
github.com/RasaHQ/rasactl/cmd.Execute()
        /go/src/rasactl/cmd/root.go:75 +0x25
main.main()
        /go/src/rasactl/main.go:32 +0xc5

To Reproduce
Steps to reproduce the behavior:

  1. Install Rasa X following the docs here.
  2. Install rasa with pip install rasa.
  3. Create new project with rasa init and cd to the project.
  4. Run rasactl connect rasa and see the output error.

Expected behavior
Rasa X should connect to Rasa OSS successfully.

Desktop (please complete the following information):

  • OS: VM with Ubuntu 20.04 (4vCPU and 16GB RAM).

rasactl version*
rasactl version 1.0.0

[`connect rasa`] Add support for action endpoint

What problem are you trying to solve?

Currently, the connect rasa doesn't support Rasa Action Server.

What's your suggested solution?

No response

Examples (if relevant)

No response

Is anything blocking this from being implemented? (if relevant)

No response

Definition of Done

The connect rasa supports Action Server.

`~/.kube/config` file is missing

I just got this error after following the installation instructions in the init branch.

(venv) ➜  rasactl git:(init) ✗ sudo ./rasactl start -p
Error: stat /root/.kube/config: no such file or directory
stat /root/.kube/config: no such file or directory

It seems like for local mode I need a ~/.kube/config file around? If that's the case, it would be good to add a section in the installation guide on how to add it. I imagine this is a file that's known for kubernetes users, but since kubernetes novices will also need to use this tool I'd argue we need to add a step to the installation guide.

How to access Rasa X web interface?

Hi, I am just deploy my Rasa X server on my server. It give me a random URL like example below.

$ rasactl status vibrant-yalow
Name:                   	vibrant-yalow
Status:                 	Running
URL:                    	http://vibrant-yalow.rasactl.localhost
Version:                	0.42.0
Enterprise:             	inactive
Rasa production version:	2.8.1
Rasa worker version:    	2.8.1
Project path:           	/home/ubuntu/test

But I can not access it by URL: http://vibrant-yalow.rasactl.localhost. How can I

Thank you so much and have a great day!

Add additional deployment statuses

What problem are you trying to solve?

Currently, if Rasa X is deploying or upgrading a deployment, rasactl status/list returns status for a given deployment as Stopped.

What's your suggested solution?

Add separate statuses for installing deployment and upgrading.

Examples (if relevant)

No response

Is anything blocking this from being implemented? (if relevant)

No response

Definition of Done

No response

Raise a warning on Docker CLI <= 20.10.0

What problem are you trying to solve?

rasactl ultilizes host-gateway, which is a feature added since docker cli 20.10.0.

When users have Docker CLI <= 20.0.3, they will see Error response from daemon: invalid IP address in add-host: "host-gateway".

What's your suggested solution?

Throw a warning on Docker CLI <= 20.10.0

Examples (if relevant)

No response

Is anything blocking this from being implemented? (if relevant)

No

Definition of Done

No response

feature flag --kubeconfig-context

In case the kubeconfig has multiple clusters configured - rasactl selects the last added cluster.

which can lead to false environment deployments.

would be good to introduce a context selector and a check with warning when multiple clusters are configured and none is selected to improve the overall experience and to lower the risk of false deployments.

rasactl should use the latest rasa-x-helm by default

What problem are you trying to solve?

In rasactl 1.0.2, rasactl start -h shows:

image

at the time of writing, the latest rasa-x helm chart is 4.3.2.

rasactl should automatically use the latest rasa-x helm chart so that customers are able to use the latest features and not get stuck troubleshooting a bug that was already fixed in a subsequent release.

What's your suggested solution?

rasactl should always use the latest rasa-x helm release

Examples (if relevant)

No response

Is anything blocking this from being implemented? (if relevant)

No response

Definition of Done

rasactl uses the latest rasa-x helm release by default

Pip installable

I just installed go in order to use this tool and it made me wonder ... is there a good reason why rasactl is written in go? I'm mainly asking because it'll be a hurdle for the average python developer. Is it possible to turn this CLI into something that is also pip install-able?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.