diff --git a/Dockerfile b/Dockerfile index 16c3378..8bf72b9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -80,5 +80,5 @@ USER libby ADD ./scripts/* ${SCRIPTS_DIR}/ RUN bash -c "echo \". ${SCRIPTS_DIR}/env\"" >> $HOME/.bashrc -CMD ["/bin/bash", "-l", "-c"] -ENTRYPOINT ["/bin/bash", "-l", "-c"] +ENTRYPOINT ["/bin/bash", "-c"] +CMD ["${SCRIPTS_DIR}/entrypoint"] diff --git a/Makefile b/Makefile index 5434a00..c688c71 100644 --- a/Makefile +++ b/Makefile @@ -19,11 +19,11 @@ daemon: build -v "${XAUTHORITY}:/home/libby/.Xauthority:ro" \ -v "/tmp/.X11-unix:/tmp/.X11-unix:ro" \ -e "DISPLAY" --security-opt label=type:container_runtime_t \ - ${LIBERO_CONTAINER} /opt/microchip/scripts/entrypoint + ${LIBERO_CONTAINER} # launch a bash shell in the libero container debug: podman exec -it -e "DISPLAY" libero bash run: - podman exec -it ${LIBERO_CONTAINER} libero + podman exec -it libero bash -cli libero diff --git a/README.org b/README.org index 7a2666e..29370ff 100644 --- a/README.org +++ b/README.org @@ -50,14 +50,35 @@ The hostname of your *host* machine will be used by the container. We can use th sed -i "s//$(hostname)/g" ./scripts/env #+end_src -* Build the container + Launch the licensing daemon +* Usage +** Build the container + Launch the licensing daemon #+begin_src bash make daemon #+end_src -* Run libero from inside the container +** Run Libero #+begin_src bash :noeval -podman exec -it --user root libero bash -. /opt/microchip/scripts/env +make run +#+end_src + +** Run libero from inside the container +#+begin_src bash :noeval +make debug libero #+end_src + + +* Common Issues +#+begin_example +Authorization required, but no authorization protocol specified +qt.qpa.xcb: could not connect to display :0 +qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found. +This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem. + +Available platform plugins are: xcb. +#+end_example + +Fix: +#+begin_src bash :noeval +xhost +"local:podman@" +#+end_src