'Unable to apply metadata using Hasura cli

I'm having a problem when running the following command:

hasura metadata apply --endpoint ${HASURA_ENDPOINT} --admin-secret ${HASURA_ADMIN_SECRET} --skip-update-check

It fails with the following error:

time="2022-05-24T12:21:04Z" level=fatal msg="error applying metadata 
cannot build actions from project: error parsing metadata 
object: actions
file: actions.yaml
error: error in converting sdl to metadata: exit status 127: Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: gnu_get_libc_version: symbol not found
Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: __register_atfork: symbol not found
Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: __strdup: symbol not found
Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: setcontext: symbol not found
Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: makecontext: symbol not found
Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: backtrace: symbol not found
Error relocating /root/.hasura/cli-ext/v2.6.2/cli-ext-306117728/cli-ext: getcontext: symbol not found"

I'm using the version v2.6.2 downloaded from here and the following configuration.

version: 2
endpoint: http://hasura:8080
metadata_directory: metadata
admin_secret: <the_secret>

The actions.yaml file is the following

actions:
- name: createProjectToken
  definition:
    kind: synchronous
    handler: "{{ACTION_BASE_URL}}/project/token/create"
  permissions:
  - role: anonymous
custom_types:
  enums: []
  input_objects: []
  objects:
  - name: ProjectToken
  scalars: []

Any idea?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source