debugging metadata #9
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Debug Metadata | |
on: | |
push: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
integration-tests: | |
name: Run TGI Integration Tests | |
runs-on: | |
group: gcp-ct5lp-hightpu-8t | |
steps: | |
- name: Install DNS utilities | |
run: | | |
sudo apt-get update -y | |
sudo apt-get install -y dnsutils iputils-ping curl resolvconf | |
- name: Configure DNS resolution | |
run: | | |
# Configure resolvconf to use Google DNS | |
sudo tee /etc/resolv.conf << EOF | |
nameserver 8.8.8.8 | |
nameserver 8.8.4.4 | |
search google.internal | |
EOF | |
# Make resolv.conf immutable to prevent automatic updates | |
sudo chattr +i /etc/resolv.conf | |
- name: Debug metadata | |
run: | | |
echo "nslookup metadata.google.internal" | |
nslookup metadata.google.internal | |
echo "ping -c 3 metadata.google.internal" | |
ping -c 3 metadata.google.internal | |
echo "ping -c 3 169.254.169.254" | |
ping -c 3 169.254.169.254 | |
echo "Get the IP address of metadata.google.internal using getent" | |
# Get the IP address of metadata.google.internal using getent | |
METADATA_IP=$(getent hosts metadata.google.internal | awk '{ print $1 }') | |
echo "Metadata server IP address: ${METADATA_IP}" | |
echo "curl -s http://metadata.google.internal/computeMetadata/v1/instance/image -H Metadata-Flavor: Google" | |
# Try to access the metadata server | |
curl "http://metadata.google.internal/computeMetadata/v1/instance/image" -H "Metadata-Flavor: Google" |