Describe the bug
[A clear and concise description of what the bug is.](fatal: could not read Username for 'https://github.com/': No such device or address)
Issue related to authentication through https of the git repo with "git pull" however adding PAT token does NOT help.
To Reproduce
workflows yaml file:
name: Deploy Streamlit App
on:
push:
branches: [ main ]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.12'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Set up Git Credentials
run: git config --global url."https://${GH_PAT}@github.com/".insteadOf "https://github.com/"
- name: Deploy to EC2
env:
EC2_SSH_PRIVATE_KEY: ${{ secrets.EC2_SSH_PRIVATE_KEY }}
GH_PAT: ${{ secrets.GH_PAT }}
EC2_HOST: 51.20.12.56
run: |
# Install SSH client
sudo apt-get update
sudo apt-get install -y ssh-client
# Set up SSH key
mkdir -p ~/.ssh
echo "$EC2_SSH_PRIVATE_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan -H "$EC2_HOST" >> ~/.ssh/known_hosts
# SSH into the EC2 instance and deploy
ssh -o StrictHostKeyChecking=no ec2-user@"$EC2_HOST" << 'ENDSSH'
# Go to the application directory
cd ~/GLN
# Pull changes from GitHub
git pull
# Activate the Python virtual environment, if you have one
source GLN/bin/activate
# Install any new dependencies
pip install -r requirements.txt
# Restart the Streamlit application
sudo systemctl restart gln.service
ENDSSH
Describe the bug [A clear and concise description of what the bug is.](fatal: could not read Username for 'https://github.com/': No such device or address)
Issue related to authentication through https of the git repo with "git pull" however adding PAT token does NOT help. To Reproduce workflows yaml file:
Runner Version and Platform
AWS/EC2/AMAZON LINUX
What's not working?
, # ~_ #### Amazon Linux 2023 ~~ _#####\ ~~ ###| ~~ #/ ___ https://aws.amazon.com/linux/amazon-linux-2023 ~~ V~' '->