Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pull_request_rules:
conditions:
- "#approved-reviews-by>=1"
- label=automerge
- status-success=Travis CI - Pull Request
- status-success=Build successful
actions:
merge:
method: merge
67 changes: 67 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@

name: Docker images

on: [push, pull_request]

jobs:
build:
name: ${{ matrix.target }} + ${{ matrix.image }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
target: [ "stable", "latest" ]
image:
- "alpine"
- "amazon-1-amd64"
- "amazon-2-amd64"
- "arch"
- "centos-6-amd64"
- "centos-7-amd64"
- "centos-8-amd64"
- "debian-10-buster-x86"
- "fedora-32-amd64"
- "fedora-33-amd64"
- "ubuntu-18.04-bionic-amd64"
- "ubuntu-20.04-focal-amd64"

steps:
- uses: actions/checkout@v2
with:
submodules: true

- name: Prepare build
run: |
sudo apt-get update && sudo apt-get install -qyy debootstrap
if [ "${{ matrix.target }}" = "latest" ]; then
git submodule update --remote Pillow
(cd Pillow && git checkout master)
fi
sudo chown -R 1000 $(pwd)

- name: Build image
run: |
cd "${{ matrix.image }}" && sudo chmod a+w . && make update
if [[ -n "$DOCKER_USERNAME" ]]; then
echo $DOCKER_PASSWORD | docker login -u $DOCKER_USERNAME --password-stdin
fi
make build BRANCH=master && make test BRANCH=master
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}

- name: Push image
if: "github.event_name == 'push' && github.ref == 'refs/heads/master' && matrix.target == 'stable'"
run: make push-${{ matrix.image }} BRANCH=master

- name: Post build
if: always()
run: sudo chown -R $(id -u) $(pwd)

success:
needs: build
runs-on: ubuntu-latest
name: Build successful
steps:
- name: Success
run: echo Build Successful
78 changes: 0 additions & 78 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ TARGETS = \
centos-6-amd64 \
centos-7-amd64 \
centos-8-amd64 \
debian-10-buster-\86 \
debian-10-buster-x86 \
fedora-32-amd64 \
fedora-33-amd64 \
ubuntu-18.04-bionic-amd64 \
Expand Down
2 changes: 1 addition & 1 deletion Makefile.sub
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
.PHONY: update build test push clean shell

WD = $(shell pwd)
USERNAME := $(shell docker info | grep Username | cut -d ' ' -f 2)
USERNAME := $(shell docker info | grep Username | xargs | cut -d ' ' -f 2)
TARGET := $(notdir $(WD))
ROOT := $(abspath $(WD)/../Pillow)
IMAGENAME := $(if $(USERNAME), $(USERNAME)/$(TARGET), $(TARGET))
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Docker Images for the Pillow Test Infrastructure

[![Build Status](https://travis-ci.com/python-pillow/docker-images.svg?branch=master)](https://travis-ci.com/github/python-pillow/docker-images)
[![Build Status](https://github.com/python-pillow/docker-images/workflows/Docker%20Images/badge.svg)](https://github.com/python-pillow/docker-images/actions?query=workflow%3A"Docker+Images")

## Getting Started

Expand Down