Skip to content

Commit

Permalink
fixes #5 - added multiarch + crossbuilding
Browse files Browse the repository at this point in the history
  • Loading branch information
jaymoulin committed Nov 23, 2017
1 parent b98b798 commit 00fda48
Show file tree
Hide file tree
Showing 7 changed files with 68 additions and 13 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.Dockerfile
*.yaml
qemu-*-static
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@ How to Contribute

This project welcomes your contribution. There are several ways to help out:

* Create an [issue](https://github.com/jaymoulin/docker-rpi-google-musicmanager/issues/) on GitHub,
* Create an [issue](https://github.com/jaymoulin/docker-google-musicmanager/issues/) on GitHub,
if you have found a bug or have an idea for a feature
* Write test cases for open bug issues
* Write patches for open bug/feature issues

Issues
------

* Submit an [issue](https://github.com/jaymoulin/docker-rpi-google-musicmanager/issues/)
* Submit an [issue](https://github.com/jaymoulin/docker-google-musicmanager/issues/)
* Make sure it does not already exist.
* Clearly describe the issue including steps to reproduce, when it is a bug.
* Make sure you note the version you use.

Additional Resources
--------------------

* [Existing issues](https://github.com/jaymoulin/docker-rpi-google-musicmanager/issues/)
* [Existing issues](https://github.com/jaymoulin/docker-google-musicmanager/issues/)
* [General GitHub documentation](https://help.github.com/)
* [GitHub pull request documentation](https://help.github.com/send-pull-requests/)
8 changes: 6 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
FROM jaymoulin/rpi-python:alpine
FROM python:alpine3.6 as builder

MAINTAINER Jay MOULIN <[email protected]>
COPY qemu-*-static /usr/bin/

FROM builder

LABEL maintainer="Jay MOULIN <[email protected]> <https://twitter.com/MoulinJay>"

ENV REMOVE=1
ENV UPLOADER_ID=false
Expand Down
20 changes: 20 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
VERSION ?= 0.6.0
FULLVERSION ?= ${VERSION}
archs = s390x arm32v7 amd64 i386 arm64v8 arm32v6

.PHONY: all build publish latest
all: build publish latest
build:
cp /usr/bin/qemu-*-static .
$(foreach arch,$(archs), \
cat Dockerfile | sed "s/FROM python:alpine/FROM ${arch}\/python:alpine/g" > .Dockerfile; \
docker build -t jaymoulin/google-musicmanager:${VERSION}-$(arch) -f .Dockerfile .;\
)
publish:
docker push jaymoulin/google-musicmanager
cat manifest.yml | sed "s/\$$VERSION/${VERSION}/g" > manifest.yaml
cat manifest.yaml | sed "s/\$$FULLVERSION/${FULLVERSION}/g" > manifest2.yaml
mv manifest2.yaml manifest.yaml
manifest-tool push from-spec manifest.yaml
latest: build
FULLVERSION=latest VERSION=${VERSION} make publish
15 changes: 7 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
![logo](logo.png)

Raspberry PI - Google Music Manager - Docker Image
==================================================
Google Music Manager - Docker Image (Multiarch)
===============================================

[![latest release](https://img.shields.io/github/release/jaymoulin/docker-rpi-google-musicmanager.svg "latest release")](http://github.com/jaymoulin/docker-rpi-google-musicmanager/releases)
[![Docker Pulls](https://img.shields.io/docker/pulls/jaymoulin/rpi-google-musicmanager.svg)](https://hub.docker.com/r/jaymoulin/rpi-google-musicmanager/)
[![Docker stars](https://img.shields.io/docker/stars/jaymoulin/rpi-google-musicmanager.svg)](https://hub.docker.com/r/jaymoulin/rpi-google-musicmanager/)
[![latest release](https://img.shields.io/github/release/jaymoulin/docker-google-musicmanager.svg "latest release")](http://github.com/jaymoulin/docker-google-musicmanager/releases)
[![Docker Pulls](https://img.shields.io/docker/pulls/jaymoulin/google-musicmanager.svg)](https://hub.docker.com/r/jaymoulin/google-musicmanager/)
[![Docker stars](https://img.shields.io/docker/stars/jaymoulin/google-musicmanager.svg)](https://hub.docker.com/r/jaymoulin/google-musicmanager/)
[![Bitcoin donation](https://github.com/jaymoulin/jaymoulin.github.io/raw/master/btc.png "Bitcoin donation")](https://m.freewallet.org/id/374ad82e/btc)
[![Litecoin donation](https://github.com/jaymoulin/jaymoulin.github.io/raw/master/ltc.png "Litecoin donation")](https://m.freewallet.org/id/374ad82e/ltc)
[![PayPal donation](https://github.com/jaymoulin/jaymoulin.github.io/raw/master/ppl.png "PayPal donation")](https://www.paypal.me/jaymoulin)
[![Beerpay donation](https://beerpay.io/jaymoulin/docker-rpi-google-musicmanager/badge.svg "Beerpay donation")](https://beerpay.io/jaymoulin/docker-rpi-google-musicmanager)

This image allows you to download and upload your Google Music Library to/from a selected folder.
This image is based on [Google MusicManager](https://github.com/jaymoulin/google-music-manager)
Expand All @@ -18,7 +17,7 @@ Installation
---

```
docker run -d --restart=always -v /path/to/your/upload/library:/media/library/upload -v /path/to/your/download/library:/media/library/download --name googlemusicmanager jaymoulin/rpi-google-musicmanager
docker run -d --restart=always -v /path/to/your/upload/library:/media/library/upload -v /path/to/your/download/library:/media/library/download --name googlemusicmanager jaymoulin/google-musicmanager
```

You must define your path to your upload library in a volume to `/media/library/upload`
Expand Down Expand Up @@ -69,7 +68,7 @@ docker restart googlemusicmanager
Appendixes
---

### Install RaspberryPi Docker
### Install Docker

If you don't have Docker installed yet, you can do it easily in one line using this command

Expand Down
Binary file modified logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
29 changes: 29 additions & 0 deletions manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
image: jaymoulin/google-musicmanager:$FULLVERSION
manifests:
-
image: jaymoulin/google-musicmanager:$VERSION-arm32v6
platform:
architecture: arm
variant: v6
os: linux
-
image: jaymoulin/google-musicmanager:$VERSION-arm64v8
platform:
architecture: arm
variant: v8
os: linux
-
image: jaymoulin/google-musicmanager:$VERSION-amd64
platform:
architecture: arm64
os: linux
-
image: jaymoulin/google-musicmanager:$VERSION-i386
platform:
architecture: 386
os: linux
-
image: jaymoulin/google-musicmanager:$VERSION-s390x
platform:
architecture: s390x
os: linux

0 comments on commit 00fda48

Please sign in to comment.