46 lines
1.2 KiB
Docker
46 lines
1.2 KiB
Docker
FROM ubuntu:latest
|
|
|
|
# Éviter les prompts interactifs
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
ENV TZ=Europe/Paris
|
|
|
|
# Installer les dépendances système
|
|
RUN apt-get update && apt-get install -y \
|
|
curl \
|
|
wget \
|
|
gnupg2 \
|
|
build-essential \
|
|
pkg-config \
|
|
libssl-dev \
|
|
libudev-dev \
|
|
usbutils \
|
|
git \
|
|
nano \
|
|
htop \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Installer Rust
|
|
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
|
ENV PATH="/root/.cargo/bin:${PATH}"
|
|
RUN rustup component add rustfmt clippy
|
|
|
|
# Installer Solana CLI (dernière version stable)
|
|
RUN sh -c "$(curl -sSfL https://release.anza.xyz/stable/install)" && \
|
|
echo 'export PATH="/root/.local/share/solana/install/active_release/bin:$PATH"' >> ~/.bashrc
|
|
|
|
# Ajouter Solana au PATH immédiatement
|
|
ENV PATH="/root/.local/share/solana/install/active_release/bin:${PATH}"
|
|
|
|
# Installer SPL Token CLI
|
|
RUN cargo install spl-token-cli
|
|
RUN cargo install mpl-token-metadata-cli
|
|
# Vérifier les installations
|
|
RUN solana --version && spl-token --version && rustc --version
|
|
|
|
# Créer dossier de travail
|
|
WORKDIR /solana-dev
|
|
VOLUME ["/solana-dev"]
|
|
|
|
# Par défaut : shell interactif avec Solana prêt
|
|
CMD ["/bin/bash"]
|