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

V1.7.9 #266

Open
wants to merge 17 commits into
base: master
Choose a base branch
from
Open
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
40 changes: 17 additions & 23 deletions .github/workflows/publish_agent_docker.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,17 @@
name: Publish Docker Agent
on:
workflow_dispatch:
inputs:
version:
description: version
required: true
type: string
is-latest:
type: boolean
description: latest
required: false
push:
branches:
- v1.7.9

jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
ref: release
ref: v1.7.9

- name: Login Docker Hub
uses: docker/login-action@v1
Expand All @@ -33,18 +27,18 @@ jobs:
with:
context: ./
file: ./Dockerfile
build-args: AGENT_VERSION=${{ inputs.version }}
build-args: AGENT_VERSION=1.7.9
builder: ${{ steps.buildx.outputs.name }}
push: true
tags: katalonstudio/agent:${{ inputs.version }}
tags: katalonstudio/agent:1.7.9

- name: Build and push Docker images
uses: docker/build-push-action@v2
if: ${{ inputs.is-latest }}
with:
context: ./
file: ./Dockerfile
build-args: AGENT_VERSION=${{ inputs.version }}
builder: ${{ steps.buildx.outputs.name }}
push: true
tags: katalonstudio/agent:latest
# - name: Build and push Docker images
# uses: docker/build-push-action@v2
# if: ${{ inputs.is-latest }}
# with:
# context: ./
# file: ./Dockerfile
# build-args: AGENT_VERSION=${{ inputs.version }}
# builder: ${{ steps.buildx.outputs.name }}
# push: true
# tags: katalonstudio/agent:latest
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ ENV KATALON_USERNAME=''
ENV KATALON_API_KEY=''
ENV TEAM_ID=''
ENV PROXY=''
ENV PROXY_EXCLUDE_LIST=''
ENV LOG_LEVEL='INFO'
ENV XVFB_RUN=''
ENV X11_DISPLAY=''
Expand Down
4 changes: 4 additions & 0 deletions cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ program
.option('-a, --agent-name <value>', 'Agent name')
.option('-c, --config <value>', 'Configuration file path')
.option('-x, --proxy <value>', 'HTTTP/HTTPS Proxy')
.option('--proxy-exclude-list <value>', 'Proxy excluded URLs')
.option('--log-level <value>', 'Log level (ALL < TRACE < DEBUG < INFO < WARN < ERROR < FATAL < MARK < OFF)')
.option('--xvfb-run <value>', 'xvfb-run options')
.option('--x11-display <value>', 'x11 DISPLAY environment variable')
Expand All @@ -44,6 +45,7 @@ program
agentName: command.agentName,
configPath: command.config,
proxy: command.proxy,
proxyExcludeList: command.proxyExcludeList,
logLevel: command.logLevel,
xvfbRun: command.xvfbRun,
x11Display: command.x11Display,
Expand All @@ -62,6 +64,7 @@ program
.option('-a, --agent-name <value>', 'Agent name')
.option('-c, --config <value>', 'Configuration file path')
.option('-x, --proxy <value>', 'HTTTP/HTTPS Proxy')
.option('--proxy-exclude-list <value>', 'Proxy excluded URLs')
.option('--ci', 'CI mode')
.action((command) => {
const options = {
Expand All @@ -72,6 +75,7 @@ program
agentName: command.agentName,
configPath: command.config,
proxy: command.proxy,
proxyExcludeList: command.proxyExcludeList,
};
if (process.platform === 'win32') {
readline
Expand Down
9 changes: 8 additions & 1 deletion docker/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,16 @@ set -xe

echo "Entrypoint"

if [ "$AUTO_UPGRADE_ENVIRONMENT" = true ]; then
if [[ "$AUTO_UPGRADE_ENVIRONMENT" = true ]]; then
/katalon/scripts/upgrade_environment.sh || true
fi

echo "Setup proxy"
#[ -f /etc/machine-id ] || echo $RANDOM | md5sum | fold -w 32 | head -n 1 > /etc/machine-id
if [[ -n "${PROXY}" ]]; then
git config --global http.proxy ${PROXY}
fi

if [ -z "$KATALON_USER_ID" ]; then
exec "$@"
else
Expand Down
1 change: 1 addition & 0 deletions docker/scripts/agent.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ cd $KATALON_AGENT_DIR
--teamid "$TEAM_ID" \
--agent-name "$AGENT_NAME" \
--proxy "$PROXY" \
--proxy-exclude-list "$PROXY_EXCLUDE_LIST" \
--log-level "$LOG_LEVEL" \
--xvfb-run "$XVFB_RUN" \
--x11-display "$X11_DISPLAY" \
Expand Down
Loading
Loading