Skip to content

Commit

Permalink
Add the ability to manually define build arguments
Browse files Browse the repository at this point in the history
Now the follow arguments can be defined manualy:
- NODE_ENV
- AC_OPTS
  • Loading branch information
danilapog authored Jan 12, 2024
1 parent 7df393d commit e414dfc
Showing 1 changed file with 21 additions and 4 deletions.
25 changes: 21 additions & 4 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,17 @@ on:
description: 'Set version that will be used for images tag'
type: string
required: true
node-env:
description: 'Set custom node_env build arg if needed'
type: string
required: false
default: production
ac-opts:
description: 'Set custom ac_opts build arg if needed'
type: string
required: false
default: no_reg

env:
PRODUCT_VERSION: ${{ github.event.inputs.version }}

jobs:
build:
name: "Build tag: ${{ github.event.inputs.version }}"
Expand All @@ -30,7 +37,17 @@ jobs:

- name: Build connector
shell: bash
env:
PRODUCT_VERSION: ${{ github.event.inputs.version }}
NODE_ENV: ${{ github.event.inputs.node-env }}
AC_OPTS: ${{ github.event.inputs.ac-opts }}
run: |
docker compose --env-file ./.env.docker.example build
docker compose --env-file ./.env.docker.example \
build \
--build-arg NODE_ENV=${NODE_ENV} \
--build-arg AC_OPTS=${AC_OPTS}
docker compose push
# Some service info about build
docker images
docker image inspect onlyoffice/confluence-cloud:${PRODUCT_VERSION}

0 comments on commit e414dfc

Please sign in to comment.