Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update DevOps #409

Merged
merged 6 commits into from
Feb 25, 2024
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
17 changes: 2 additions & 15 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,33 +5,21 @@ on: [push, pull_request]
jobs:
build:
name: Build
runs-on: ${{ matrix.os }}
env:
CGO_CFLAGS_ALLOW: -Xpreprocessor
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ubuntu-latest

steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
go-version: ^1.21

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Install linux deps
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get -y install libopenjp2-7
sudo apt-get -y install libvips-dev

- name: Install macos deps
if: matrix.os == 'macos-latest'
run: |
brew install vips

- name: Get dependencies
run: |
go get -v -t -d ./...
Expand All @@ -43,7 +31,6 @@ jobs:
run: go test -v -coverprofile=profile.cov ./...

- name: Coveralls
if: matrix.os == 'ubuntu-latest'
uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: profile.cov
27 changes: 0 additions & 27 deletions build/Dockerfile-ubuntu-18.04

This file was deleted.

29 changes: 0 additions & 29 deletions build/Dockerfile-ubuntu-20.04

This file was deleted.

5 changes: 3 additions & 2 deletions build/Dockerfile-ubuntu-20.10
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# This Dockerfile can be used to build Ubuntu/Debian packages with govips

FROM ubuntu:20.10

ENV DEBIAN_FRONTEND noninteractive
Expand All @@ -9,7 +11,6 @@ RUN apt-get update
RUN apt-get -y --no-install-recommends install software-properties-common gpg-agent
RUN apt-get -y --no-install-recommends install \
build-essential devscripts lsb-release dput wget git golang nvi
RUN add-apt-repository -y ppa:tonimelisma/ppa
RUN apt-get -y install --no-install-recommends libvips-dev
RUN go get golang.org/dl/go1.15.4
RUN ~/go/bin/go1.15.4 download
Expand All @@ -20,7 +21,7 @@ RUN cd ~/go/src/github.com/davidbyttow/govips && ~/go/bin/go1.15.4 test -v ./...


ENV DEBFULLNAME="Toni Melisma"
ENV DEBEMAIL="toni.melisma@iki.fi"
ENV DEBEMAIL="toni@melisma.net"
ENV PPANAME="tonimelisma"
ENV DISTRIBUTION="groovy"
ENV DISTVERSION="20.10"
Expand Down
17 changes: 17 additions & 0 deletions build/Dockerfile-ubuntu-23.10
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# This Dockerfile can be used to test and build govips

FROM ubuntu:23.10

ENV DEBIAN_FRONTEND noninteractive

# Enable deb-src APT sources and get build tools
RUN sed -e '/^#\sdeb-src /s/^# *//;t;d' "/etc/apt/sources.list" \
>> "/etc/apt/sources.list.d/ubuntu-sources.list"
RUN apt-get update
RUN apt-get -y --no-install-recommends install \
build-essential git golang
RUN apt-get -y --no-install-recommends install ca-certificates
RUN apt-get -y --no-install-recommends install lsb-release
RUN apt-get -y install --no-install-recommends libvips-dev
RUN mkdir -p ~/go/src/github.com/davidbyttow
RUN cd ~/go/src/github.com/davidbyttow && git clone -v https://github.com/davidbyttow/govips.git
8 changes: 2 additions & 6 deletions build/build.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
#!/bin/sh

docker build -t govips-ubuntu:18.04 -f Dockerfile-ubuntu-18.04 ./ || (echo build failed 1>&2 && exit 1)
docker build -t govips-ubuntu:20.04 -f Dockerfile-ubuntu-20.04 ./ || (echo build failed 1>&2 && exit 1)
docker build -t govips-ubuntu:20.10 -f Dockerfile-ubuntu-20.10 ./ || (echo build failed 1>&2 && exit 1)
docker build -t govips-ubuntu:23.10 -f Dockerfile-ubuntu-23.10 ./ || (echo build failed 1>&2 && exit 1)

mkdir -p /tmp/volume

echo To run the container:
echo docker run --rm -it -v /tmp/volume:/volume govips-ubuntu:18.04
echo docker run --rm -it -v /tmp/volume:/volume govips-ubuntu:20.04
echo docker run --rm -it -v /tmp/volume:/volume govips-ubuntu:20.10
echo docker run --rm -it -v /tmp/volume:/volume govips-ubuntu:23.10
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Binary file not shown.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Loading