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

eb init failing #145

Open
1 task done
aelhennawy opened this issue Apr 28, 2023 · 1 comment
Open
1 task done

eb init failing #145

aelhennawy opened this issue Apr 28, 2023 · 1 comment

Comments

@aelhennawy
Copy link

aelhennawy commented Apr 28, 2023

1. Please specify the following:

  • OS: Amazon Linux 2

  • I have reviewed the troubleshooting tips described here and they do not solve my problem

2. Description

I have an AWS Pipeline pulling my source code from github and deploying it to the Elastic Beanstalk using a buildspec.yml file
The deployment was working fine until today i keep getting this error

"Import Error urllib3 v2.0 only supports OpenSSL 1.1.1+, currently the 'ssl' module is compiled with OpenSSL 1.0.2k-fips"

I found that the urllib3 had an update on 2023-04-26 which removed the support of OpenSSL versions earlier than 1.1.1
The default OpenSSL installed on my build machine is v1.0.2

I've tried to install OpenSSL v1.1.1 using this command **yum install openssl11 openssl11-devel ** but i still get the same error
How can i recompile the 'ssl' module with the new version of the OpenSSL

buildspec.yml content

version: "0.2"
phases:
  install:
    runtime-versions:
      java: corretto8
    commands:
      - yum install openssl11 openssl11-devel ncurses-devel libffi-devel sqlite-devel.x86_64 readline-devel.x86_64 bzip2-devel.x86_64 -y
      - git clone https://github.com/aws/aws-elastic-beanstalk-cli-setup.git
      - python aws-elastic-beanstalk-cli-setup/scripts/ebcli_installer.py
      - echo 'export PATH="/root/.ebcli-virtual-env/executables:$PATH"' >> ~/.bash_profile && source ~/.bash_profile
  pre_build:
    commands:
      - echo "Entered the pre-build phase"
  build:
    commands:
      - echo "Entered build phase"
      - mvn clean compile install
  post_build:
    commands:
      - echo "Entered Post build phase (deploy phase)"
      - eb init $AWS_EB_APP_NAME -r $AWS_EB_REGION
      - eb use $AWS_EB_ENV_NAME
      - eb deploy --staged -nh
artifacts:
  files:
    - target/*.jar
cache:
  paths:
    - "/root/.m2/**/*"

Screenshot of the error

image

@shishirTimsina1
Copy link

I faced a similar issue, I was able to solve it by doing
pip3 install "urllib3<2" on the ec2 instance
maybe that solves your problem as well

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