Skip to content

Instantly share code, notes, and snippets.

@Anush-DP
Created February 19, 2024 12:28
Show Gist options
  • Select an option

  • Save Anush-DP/3bc7e52ce7f9769081b8da0ec44a85f3 to your computer and use it in GitHub Desktop.

Select an option

Save Anush-DP/3bc7e52ce7f9769081b8da0ec44a85f3 to your computer and use it in GitHub Desktop.

Revisions

  1. Anush-DP created this gist Feb 19, 2024.
    36 changes: 36 additions & 0 deletions Dockerfile
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,36 @@
    FROM ubuntu:22.04
    RUN apt update
    RUN apt install \
    libncurses5 \
    libstdc++5 \
    libmotif-dev \
    xfonts-75dpi \
    xfonts-100dpi \
    libxi6 \
    libxrandr2 -y
    CMD bash

    # edit sshd_config to add X11Forwarding (since installing ISE requires a GUI)
    # $ sudo cp /etc/ssh/sshd_config /etc/ssh/sshd_config.orig
    # $ sudo vim /etc/ssh/sshd_config
    # ...
    # X11Forwarding yes
    # X11UseLocalhost no
    # ...

    # We also need to open the forwarded X server port in the Docker virtual interface.
    # By default, the X server of the host listens only in lo.
    # The best option is to allow only local connections from the Docker ports with xhost:

    # $ sudo xhost +local:docker

    # build the docker image
    # docker buildx build --rm --tag xilinx-image --file ./Dockerfile .

    # run the image in a container with mounting install volume (/opt/Xilinx) and volume with setup files (xsetup), here I have used $(pwd)
    # (you can download and extract the tar https://www.xilinx.com/downloadNav/vivado-design-tools/archive-ise.html)
    # docker run --rm -v /opt/Xilinx:/opt/Xilinx -v $(pwd):/home --net=host --env DISPLAY=$DISPLAY -it xilinx-image

    # in the container cd to home and run ./xsetup to start the setup

    # another helpful gist https://gist.github.com/alimpk/ce58ea570ee6ffa6dedfa569f87f1c1e