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

libc.musl-x86_64.so.1: cannot open shared object file: #68

Open
sergiors opened this issue Jun 2, 2022 · 3 comments
Open

libc.musl-x86_64.so.1: cannot open shared object file: #68

sergiors opened this issue Jun 2, 2022 · 3 comments

Comments

@sergiors
Copy link

sergiors commented Jun 2, 2022

Hi, recently I added the following workflow to my project:

name: Deploy main branch

on:
  push:
    branches:
      - main

jobs:
  deploy:
    name: deploy
    runs-on: ubuntu-latest
    strategy:
      matrix:
        node-version: [14.x]
    steps:
      - uses: actions/checkout@v3
      - name: Use Node.js ${{ matrix.node-version }}
        uses: actions/setup-node@v3
        with:
          node-version: ${{ matrix.node-version }}
      - name: Install Plugin and Deploy
        uses: serverless/github-action@v3
        with:
          args: -c "serverless plugin install --name serverless-python-requirements && serverless deploy --stage prod --verbose"
          entrypoint: /bin/sh
        env:
          AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
          AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

The functions that have pydantic as a dependency, suddenly throw the following error:

Unable to import module 'http_api.sign_up.app': libc.musl-x86_64.so.1: cannot open shared object file: No such file or directory
Traceback (most recent call last):

If I deploy from my computer, the function works fine.

Does anyone have any idea what the heck happened?

@DavideViolante
Copy link
Contributor

Let me know if this happens with uses: serverless/[email protected] too

@sergiors
Copy link
Author

Let me know if this happens with uses: serverless/[email protected] too

@DavideViolante I did not run it, because lambda does not support python 3.10 yet

@sergiors
Copy link
Author

I solved the problem using the following action:

name: Deploy main branch

on:
  push:
    branches:
      - main

jobs:
  deploy:
    name: deploy
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - uses: actions/setup-python@v4
        with:
          python-version: "3.9"
      - run: curl -sSL https://install.python-poetry.org | python3 -
      - uses: actions/setup-node@v3
        with:
          node-version: 16
      - run: npm install
      - run: npx serverless deploy --stage dev
        env:
          AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
          AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

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

2 participants