Move from deprecated image labels to modern standard.
This commit is contained in:
+13
-14
@@ -1,14 +1,13 @@
|
||||
name: Build
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
tags:
|
||||
- v*.*.*
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
tags:
|
||||
- v*.*.*
|
||||
|
||||
jobs:
|
||||
|
||||
build:
|
||||
name: Build docker images.
|
||||
runs-on: ubuntu-latest
|
||||
@@ -20,30 +19,30 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout repository.
|
||||
uses: actions/checkout@v2
|
||||
|
||||
|
||||
- name: Get version from tag.
|
||||
uses: little-core-labs/get-git-tag@v3.0.2
|
||||
|
||||
- name: Get build date/time.
|
||||
id: date
|
||||
run: echo "::set-output name=date::$(date --rfc-3339=seconds)"
|
||||
run: echo "::set-output name=date::$(date -u --rfc-3339=seconds)"
|
||||
|
||||
- name: Set up QEMU.
|
||||
id: qemu
|
||||
uses: docker/setup-qemu-action@v1
|
||||
with:
|
||||
platforms: arm64
|
||||
|
||||
|
||||
- name: Set up Docker Buildx.
|
||||
uses: docker/setup-buildx-action@v1
|
||||
|
||||
|
||||
- name: Login to GHCR.
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
|
||||
- name: Login to DockerHub.
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
@@ -55,6 +54,6 @@ jobs:
|
||||
with:
|
||||
files: "docker-bake.hcl"
|
||||
env:
|
||||
VCS_REF: ${{ github.sha }}
|
||||
VERSION: ${{ env.GITHUB_TAG_NAME }}
|
||||
BUILD_DATE: ${{ steps.date.outputs.date }}
|
||||
VCS_REF: ${{ github.sha }}
|
||||
VERSION: ${{ env.GIT_TAG_NAME }}
|
||||
BUILD_DATE: ${{ steps.date.outputs.date }}
|
||||
|
||||
+10
-11
@@ -21,20 +21,19 @@ FROM nginx:mainline-alpine
|
||||
|
||||
ARG BUILD_DATE
|
||||
ARG VCS_REF
|
||||
ARG VERSION=dev
|
||||
ARG VERSION=$VCS_REF-dev
|
||||
|
||||
EXPOSE 8080
|
||||
|
||||
LABEL maintainer="team@rereadgames.com"
|
||||
LABEL org.label-schema.name="massivedecks/client"
|
||||
LABEL org.label-schema.description="The web client for Massive Decks, a comedy party game."
|
||||
LABEL org.label-schema.url="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.label-schema.vcs-url="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.label-schema.vendor="Reread Games"
|
||||
LABEL org.label-schema.schema-version="1.0"
|
||||
LABEL org.label-schema.build-date=$BUILD_DATE
|
||||
LABEL org.label-schema.vcs-ref=$VCS_REF
|
||||
LABEL org.label-schema.version=$VERSION
|
||||
LABEL org.opencontainers.image.created=$BUILD_DATE
|
||||
LABEL org.opencontainers.image.url="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.opencontainers.image.source="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.opencontainers.image.version=$VERSION
|
||||
LABEL org.opencontainers.image.revision=$VCS_REF
|
||||
LABEL org.opencontainers.image.vendor="Reread Games <team@rereadgames.com>"
|
||||
LABEL org.opencontainers.image.licenses="AGPL-3.0+"
|
||||
LABEL org.opencontainers.image.title="Massive Decks (Client)"
|
||||
LABEL org.opencontainers.image.description="The web client for Massive Decks, a comedy party game."
|
||||
|
||||
COPY --from=build ["/md/dist", "/usr/share/nginx/html/"]
|
||||
COPY ["./nginx.conf", "/etc/nginx/nginx.conf"]
|
||||
|
||||
+10
-11
@@ -13,20 +13,19 @@ FROM node:16-alpine
|
||||
|
||||
ARG BUILD_DATE
|
||||
ARG VCS_REF
|
||||
ARG VERSION=dev
|
||||
ARG VERSION=$VCS_REF-dev
|
||||
|
||||
ENV MD_VERSION $VERSION
|
||||
|
||||
LABEL maintainer="team@rereadgames.com"
|
||||
LABEL org.label-schema.name="massivedecks/server"
|
||||
LABEL org.label-schema.description="The web server for Massive Decks, a comedy party game."
|
||||
LABEL org.label-schema.url="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.label-schema.vcs-url="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.label-schema.vendor="Reread Games"
|
||||
LABEL org.label-schema.schema-version="1.0"
|
||||
LABEL org.label-schema.build-date=$BUILD_DATE
|
||||
LABEL org.label-schema.vcs-ref=$VCS_REF
|
||||
LABEL org.label-schema.version=$VERSION
|
||||
LABEL org.opencontainers.image.created=$BUILD_DATE
|
||||
LABEL org.opencontainers.image.url="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.opencontainers.image.source="https://github.com/Lattyware/massivedecks"
|
||||
LABEL org.opencontainers.image.version=$VERSION
|
||||
LABEL org.opencontainers.image.revision=$VCS_REF
|
||||
LABEL org.opencontainers.image.vendor="Reread Games <team@rereadgames.com>"
|
||||
LABEL org.opencontainers.image.licenses="AGPL-3.0+"
|
||||
LABEL org.opencontainers.image.title="Massive Decks (Server)"
|
||||
LABEL org.opencontainers.image.description="The web server for Massive Decks, a comedy party game."
|
||||
|
||||
WORKDIR /md
|
||||
|
||||
|
||||
Reference in New Issue
Block a user