pyth-crosschain/third_party/pyth/Dockerfile.pyth

39 lines
1.0 KiB
Docker

# syntax=docker/dockerfile:1.2
# Wormhole-specific setup for pyth
FROM pythfoundation/pyth-client:devnet-v2.12.0
USER root
# At the time of this writing, debian is fussy about performing an
# apt-get update. Please add one if repos go stale
RUN apt-get install -y netcat-openbsd python3 && \
rm -rf /var/lib/apt/lists/*
ADD tilt-devnet/secrets/solana/ /solana-secrets
ENV PYTH_KEY_STORE=/home/pyth/.pythd
# Prepare keys
WORKDIR $PYTH_KEY_STORE
RUN cp /solana-secrets/pyth_publisher.json publish_key_pair.json && \
cp /solana-secrets/pyth_program.json program_key_pair.json && \
chown pyth:pyth -R . && \
chmod go-rwx -R .
ENV PYTH_SRC_ROOT=/home/pyth/pyth-client
WORKDIR $PYTH_SRC_ROOT/build
# Prepare setup script
ADD third_party/pyth/pyth_utils.py /opt/pyth/pyth_utils.py
ADD third_party/pyth/pyth_publisher.py /opt/pyth/pyth_publisher.py
RUN chmod a+rx /opt/pyth/*.py
USER pyth
ENV PYTH=$PYTH_SRC_ROOT/build/pyth
ENV PYTH_ADMIN=$PYTH_SRC_ROOT/build/pyth_admin
ENV READINESS_PORT=2000
ENV SOL_AIRDROP_AMT=100