Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Knowage Dataset Python Error 401 (Linux VM) #52

Open
HugoT852 opened this issue Dec 9, 2021 · 1 comment
Open

Knowage Dataset Python Error 401 (Linux VM) #52

HugoT852 opened this issue Dec 9, 2021 · 1 comment

Comments

@HugoT852
Copy link

HugoT852 commented Dec 9, 2021

Hi,

I am currently using the Knowage Docker Server on a linux VM and I would like to create a Python dataset but I am struggling to make it work.

Following the documentation, I modify the python variable of category PYTHON_CONFIGURATION:
python.default.environment.url, http://knowagepython:5000

The REST methode work (code 200).
I can see the Python libraries.
I have authorize Edit Python/R Scripts in configuration.

When trying to preview the python dataset I get the following : The response status is not ok: status=401, response=Unauthorized
[2021-12-09 09:30:53 +0000] [18] [DEBUG] GET /dataset/libraries
172.24.0.7 - - [09/Dec/2021:09:30:53 +0000] "GET /dataset/libraries HTTP/1.1" 200 1339 "-" "Jakarta Commons-HttpClient/3.0.1"

Here is my docker-compose file :

version: "3.1"
services:
knowage:
image: knowagelabs/knowage-server-docker:8.0.4
depends_on:
- knowagedb
- knowagecache
- hazelcast
ports:
- "8080:8080"
networks:
- main
environment:
- DB_HOST=$DB_HOST
- DB_PORT=$DB_PORT
- DB_DB=$DB_DB
- DB_USER=$DB_USER
- DB_PASS=$DB_PASS

  - CACHE_DB_HOST=$CACHE_DB_HOST
  - CACHE_DB_PORT=$CACHE_DB_PORT
  - CACHE_DB_DB=$CACHE_DB_DB
  - CACHE_DB_USER=$CACHE_DB_USER
  - CACHE_DB_PASS=$CACHE_DB_PASS

  - HMAC_KEY=$HMAC_KEY
  - PASSWORD_ENCRYPTION_SECRET=$PASSWORD_ENCRYPTION_SECRET
  - PUBLIC_ADDRESS=knowage

  - HAZELCAST_HOSTS=hazelcast
  - HAZELCAST_PORT=5701
volumes:
  - ./resources:/home/knowage/apache-tomcat/resources

hazelcast:
image: hazelcast/hazelcast:3.6.5
networks:
- main
environment:
- JAVA_OPTS=-Dhazelcast.local.publicAddress=hazelcast -Dhazelcast.config=/opt/hazelcast/hazelcast.xml
volumes:
- ./hazelcast-server.xml:/opt/hazelcast/hazelcast.xml

knowagepython:
image: knowagelabs/knowage-python-docker:8.0.4
environment:
- HMAC_KEY=$HMAC_KEY
- KNOWAGE_PUBLIC_ADDRESS=knowage
- PUBLIC_ADDRESS=knowagepython
networks:
- main
ports:
- "5000:5000"

knowager:
image: knowagelabs/knowage-r-docker:8.0.4
environment:
- HMAC_KEY=$HMAC_KEY
networks:
- main

knowagedb:
image: mariadb:10.3
environment:
- MYSQL_USER=$DB_USER
- MYSQL_PASSWORD=$DB_PASS
- MYSQL_DATABASE=$DB_DB
- MYSQL_RANDOM_ROOT_PASSWORD=yes
networks:
- main
volumes:
- "db:/var/lib/mysql"

knowagecache:
image: mariadb:10.3
environment:
- MYSQL_USER=$CACHE_DB_USER
- MYSQL_PASSWORD=$CACHE_DB_PASS
- MYSQL_DATABASE=$CACHE_DB_DB
- MYSQL_RANDOM_ROOT_PASSWORD=yes
networks:
- main
volumes:
- "cache:/var/lib/mysql"

volumes:
db:
cache:

networks:
main:

@HugoT852
Copy link
Author

HugoT852 commented Dec 9, 2021

add @agaldemas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant