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
3 changes: 2 additions & 1 deletion .github/workflows/prepare-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@ jobs:
filters: |
src:
- '.github/workflows/docker-images.yml'
- 'docker/!(windowsDockerfile)'
- 'docker/ubuntu**'
- 'docker/fedora**'
- 'requirements/!(windows.txt|macos.txt)'
- 'scripts/build_thirdparty.sh'
- 'scripts/install_**.sh'
Expand Down
56 changes: 56 additions & 0 deletions .github/workflows/update-app-container.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Update MeshLib app containers

on:
release:
types: [ published ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
update-app-container:
runs-on: ubuntu-latest
strategy:
matrix:
os: [ Ubuntu-20, Ubuntu-22, Fedora-35 ]
include:
- os: Ubuntu-20
image-tag: ubuntu20
file-path-end: _ubuntu20-dev.deb
- os: Ubuntu-22
image-tag: ubuntu22
file-path-end: _ubuntu22-dev.deb
- os: Fedora-35
image-tag: fedora35
file-path-end: -dev.rpm
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Get latests release
id: get_release
uses: kaliber5/action-get-release@v1
with:
token: ${{ secrets.BUILD_MACHINE_TOKEN }}
latest: true

- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: meshrus
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Set variables
id: set-vars
run: |
echo "::set-output name=file_name::meshlib_${{steps.get_release.outputs.tag_name }}${{matrix.file-path-end}}"
echo "::set-output name=file_url::https://github.com/MeshInspector/MeshLib/releases/download/${{ steps.get_release.outputs.tag_name }}/${{steps.set-vars.outputs.file_name}}"

- name: Build and push
uses: docker/build-push-action@v3
with:
file: ./docker/app/${{matrix.image-tag}}Dockerfile
push: true
tags: meshrus/meshlib-app-test:${{ matrix.image-tag }}
build-args: |
file_name=${{steps.set-vars.outputs.file_name}}
file_url=${{steps.set-vars.outputs.file_url}}
12 changes: 12 additions & 0 deletions docker/app/fedora35Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
ARG file_name
ARG file_url

FROM fedora:35 AS build

RUN dnf -y update && \
dnf -y install sudo python3-pip wget && \
dnf clean all

RUN wget -O /tmp/${file_name} ${file_url} && \
rpm -ivh /tmp/${file_name} && \
rm /tmp/${file_name}
19 changes: 19 additions & 0 deletions docker/app/ubuntu20Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
ARG file_name
ARG file_url

FROM ubuntu:20.04

# update and install req
RUN export DEBIAN_FRONTEND=noninteractive; \
export DEBCONF_NONINTERACTIVE_SEEN=true; \
echo 'tzdata tzdata/Areas select Etc' | debconf-set-selections; \
echo 'tzdata tzdata/Zones/Etc select UTC' | debconf-set-selections; \
apt-get update -qqy \
&& apt-get install -qqy --no-install-recommends \
tzdata sudo python3-pip wget\
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

RUN wget -O /tmp/{file_name} ${file_url} && \
dpkg -i /tmp/{file_name} && \
rm /tmp/{file_name}
19 changes: 19 additions & 0 deletions docker/app/ubuntu22Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
ARG file_name
ARG file_url

FROM ubuntu:22.04

# update and install req
RUN export DEBIAN_FRONTEND=noninteractive; \
export DEBCONF_NONINTERACTIVE_SEEN=true; \
echo 'tzdata tzdata/Areas select Etc' | debconf-set-selections; \
echo 'tzdata tzdata/Zones/Etc select UTC' | debconf-set-selections; \
apt-get update -qqy \
&& apt-get install -qqy --no-install-recommends \
tzdata sudo python3-pip wget\
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

RUN wget -O /tmp/{file_name} ${file_url} && \
dpkg -i /tmp/{file_name} && \
rm /tmp/{file_name}