luminance icon indicating copy to clipboard operation
luminance copied to clipboard

Simplify installation

Open MichaPoe opened this issue 6 years ago • 1 comments
trafficstars

I tried to install it on my ubuntu 18.04 and 19.04 machines. But it was a bit hard. I am not a python developer so I also did not want to install all the dev tools on my machine. But I am using docker a lot so I decided to create a tiny install script being able to to all the "dirty" work there. I wanted to share this, as this might help other guys aswell. Here we go:

#/bin/sh
sudo apt install -y python3-pip
sudo pip3 install phue

mkdir /tmp/hue-luminance 2>>/dev/null
cd /tmp/hue-luminance

cat <<- EOF > Dockerfile
	FROM ubuntu:18.04
	RUN apt-get update && apt-get install -y \
		git python3-pip autoconf autogen build-essential python-gi-dev libgtk-3-dev gsettings-desktop-schemas-dev libgnome-desktop-3-dev libxml2-utils
	RUN pip3 install phue
	RUN mkdir -p /tmp/install
	WORKDIR /tmp/install
	RUN git clone https://github.com/craigcabrey/luminance.git
	WORKDIR /tmp/install/luminance
	CMD ./autogen.sh && ./configure --prefix=/usr/local && make && make install
	VOLUME /usr/local
EOF

docker build . -t hue-luminance
docker run --rm --mount type=bind,src=/usr/local,target=/usr/local hue-luminance
docker rmi hue-luminance

MichaPoe avatar Aug 18 '19 07:08 MichaPoe

Maybe it would be good to have an official Docker image in general at Docker Hub, GitLab or GitHub?

alexanderadam avatar Aug 14 '20 08:08 alexanderadam