102 lines
3.0 KiB
YAML
102 lines
3.0 KiB
YAML
name: Docker next-terminal Build
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
days:
|
|
description: 'Number of days.'
|
|
required: true
|
|
default: "20"
|
|
|
|
jobs:
|
|
DOCKERHUB_next-terminal_Build:
|
|
name: Docker next-terminal Build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
-
|
|
name: Private Actions Checkout
|
|
uses: actions/checkout@v2.3.4
|
|
-
|
|
name: Docker Setup QEMU
|
|
uses: docker/setup-qemu-action@v1.2.0
|
|
-
|
|
name: Docker Setup Buildx
|
|
uses: docker/setup-buildx-action@v1.6.0
|
|
-
|
|
name: node Setup
|
|
uses: actions/setup-node@v2
|
|
with:
|
|
node-version: '14'
|
|
-
|
|
name: npm install
|
|
run: |
|
|
cd web
|
|
npm install
|
|
npm run build
|
|
-
|
|
name: Docker Login
|
|
uses: docker/login-action@v1.10.0
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
|
-
|
|
name: Build and push Docker images
|
|
uses: docker/build-push-action@v2.7.0
|
|
with:
|
|
context: .
|
|
platforms: linux/arm64,linux/amd64
|
|
file: Dockerfile
|
|
push: true
|
|
tags: |
|
|
${{ secrets.DOCKERHUB_USERNAME }}/next-terminal:latest
|
|
cache-from: type=registry,ref=${{ secrets.DOCKERHUB_USERNAME }}/next-terminal:cache
|
|
cache-to: type=registry,ref=${{ secrets.DOCKERHUB_USERNAME }}/next-terminal:cache,mode=max
|
|
|
|
DOCKERHUB_Guacd_Build:
|
|
name: Docker Guacd Build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
-
|
|
name: Private Actions Checkout
|
|
uses: actions/checkout@v2.3.4
|
|
-
|
|
name: Docker Setup QEMU
|
|
uses: docker/setup-qemu-action@v1.2.0
|
|
-
|
|
name: Docker Setup Buildx
|
|
uses: docker/setup-buildx-action@v1.6.0
|
|
-
|
|
name: Docker Login
|
|
uses: docker/login-action@v1.10.0
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
|
-
|
|
name: Build and push Docker images
|
|
uses: docker/build-push-action@v2.7.0
|
|
with:
|
|
context: .
|
|
platforms: linux/arm64,linux/amd64
|
|
file: guacd/Dockerfile
|
|
push: true
|
|
tags: |
|
|
${{ secrets.DOCKERHUB_USERNAME }}/guacd:1.3.0
|
|
cache-from: type=registry,ref=${{ secrets.DOCKERHUB_USERNAME }}/guacd:cache
|
|
cache-to: type=registry,ref=${{ secrets.DOCKERHUB_USERNAME }}/guacd:cache,mode=max
|
|
|
|
DOCKERHUB_Hub_Description:
|
|
needs: [DOCKERHUB_next-terminal_Build, DOCKERHUB_Guacd_Build]
|
|
name: Change DockerHub Description
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
-
|
|
name: Private Actions Checkout
|
|
uses: actions/checkout@v2.3.4
|
|
-
|
|
name: Docker Hub Description
|
|
uses: peter-evans/dockerhub-description@v2
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
|
repository: ${{ secrets.DOCKERHUB_USERNAME }}/next-terminal
|