Skip to content

Instantly share code, notes, and snippets.

@daluu
Created April 7, 2019 22:01
Show Gist options
  • Save daluu/49f331f9fc6ef110ac48bfa4f30eaeef to your computer and use it in GitHub Desktop.
Save daluu/49f331f9fc6ef110ac48bfa4f30eaeef to your computer and use it in GitHub Desktop.
Notes for building custom Robot Framework docker images
Below are various notes to help if building a custom RF docker image that we don't already have publicly available,
e.g. IronPython-based RF docker image, Java/Jython-based RF docker image.
java -jar jython_installer-<version>.jar
# Robot Framework 3.0 supports Jython 2.7 which requires Java 7 or newer.
jython -m ensurepip
jython -m pip install robotframework
# Robot Framework 2.5-2.8 support Jython 2.5 (requires Java 5 or newer)
# Robot Framework 2.0-2.1 support Jython 2.2
java -jar robotframework-3.0.jar mytests.robot
java -jar robotframework-3.0.jar --variable name:value mytests.robot
java -jar robotframework-3.0.jar rebot output.xml
java -jar robotframework-3.0.jar libdoc MyLibrary list
java -jar robotframework-3.0.jar %s
###
wget https://github.com/ombre42/jrobotremoteserver/releases/download/jrobotremoteserver-standalone-3.0/jrobotremoteserver-3.0-standalone.jar
wget https://github.com/downloads/ombre42/jrobotremoteserver/jrobotremoteserver-standalone-2.0.jar
# First configure the CLASSPATH to include your libraries and jrobotremoteserver
java org.robotframework.remoteserver.RemoteServer %s
# ipy
FROM mono:latest
RUN msbuild MySolution.sln
RUN mono MyConsoleApp.exe
# IronPython 2.7.5
# any newer versions to install?
wget https://github.com/IronLanguages/main/releases/download/ipy-2.7.7-rc2/IronPython-2.7.7rc2-unix.tar.bz2
https://github.com/IronLanguages/main/releases/download/ipy-2.7.7/IronPython-2.7.7-win.zip
https://github.com/IronLanguages/main/releases/download/ipy-2.7.7/IronPython-2.7.7.msi
wget http://effbot.org/media/downloads/elementtree-1.2.7-20070827-preview.zip
ipy setup.py install
# IronPython contains bundled pip starting from version 2.7.5
ipy -X:Frames -m ensurepip
ipy -X:Frames -m pip install robotframework
ipy -m robot %s
ipy path/to/robot/ %s
###
dotnet add package NRobotServer --version 1.0.0
Install-Package NRobotServer -Version 1.0.0
wget https://www.nuget.org/api/v2/package/NRobotServer/1.0.0
# then extract nrobotserver.1.0.0.nupkg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment