Skip to content

Commit

Permalink
fix(build): Tried making the Docker build successfully build plc4py
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisdutz committed Jul 25, 2022
1 parent 1041868 commit 639c03a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
8 changes: 7 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,10 @@
Dockerfile
.dockerignore
.git/**
**/target/**
**/target/**
sandbox/plc4py/.eggs
sandbox/plc4py/.pytest_cache
sandbox/plc4py/build
sandbox/plc4py/dist
sandbox/plc4py/plc4py.egg-info
sandbox/plc4py/venv
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ RUN dos2unix .mvn/wrapper/maven-wrapper.properties
# Tell Maven to fetch all needed dependencies first, so they can get cached
# (Tried a patched version of the plugin to allow exclusion of inner artifacts.
# See https://issues.apache.org/jira/browse/MDEP-568 for details)
RUN ./mvnw -Dpython.venv.dir=./docker-venv -Dpython.venv.bin=docker-venv/bin/ -P with-c,with-dotnet,with-go,with-python,with-sandbox com.offbytwo.maven.plugins:maven-dependency-plugin:3.1.1.MDEP568:go-offline -DexcludeGroupIds=org.apache.plc4x,org.apache.plc4x.examples,org.apache.plc4x.sandbox
RUN ./mvnw -P with-c,with-dotnet,with-go,with-sandbox com.offbytwo.maven.plugins:maven-dependency-plugin:3.1.1.MDEP568:go-offline -DexcludeGroupIds=org.apache.plc4x,org.apache.plc4x.examples,org.apache.plc4x.sandbox

# Build everything with all tests
RUN ./mvnw -Dpython.venv.dir=./docker-venv -Dpython.venv.bin=docker-venv/bin/ -P with-c,with-dotnet,with-go,with-python,with-sandbox install
RUN ./mvnw -P with-c,with-dotnet,with-go,with-sandbox install

# Get the version of the project and save it in a local file on the container
RUN ./mvnw org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.version -DforceStdout -q -pl . > project_version
Expand Down
3 changes: 0 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1574,7 +1574,6 @@
<cmake.root>${project.build.directory}/cmake-${cmake-version}-linux-${os.arch}/bin/</cmake.root>
<cmake.generator>Unix Makefiles</cmake.generator>
<python.venv.bin>venv/bin/</python.venv.bin>
<python.venv.dir>./venv</python.venv.dir>
</properties>
</profile>
<!-- Profile for mac (Self-Enabling) -->
Expand All @@ -1592,7 +1591,6 @@
<cmake.root>${project.build.directory}/cmake-${cmake-version}-macos-universal/CMake.app/Contents/bin</cmake.root>
<cmake.generator>Unix Makefiles</cmake.generator>
<python.venv.bin>venv/bin/</python.venv.bin>
<python.venv.dir>./venv</python.venv.dir>
</properties>
</profile>
<!-- profile for windows (Self-Enabling) -->
Expand All @@ -1610,7 +1608,6 @@
<cmake.root>${project.build.directory}/cmake-${cmake-version}-windows-x86_64/bin</cmake.root>
<cmake.generator>MinGW Makefiles</cmake.generator>
<python.venv.bin>venv/Scripts/</python.venv.bin>
<python.venv.dir>./venv</python.venv.dir>
</properties>
</profile>

Expand Down
2 changes: 1 addition & 1 deletion sandbox/plc4py/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
<arguments>
<argument>-m</argument>
<argument>venv</argument>
<argument>${python.venv.dir}</argument>
<argument> ./venv</argument>
</arguments>
</configuration>
</execution>
Expand Down

0 comments on commit 639c03a

Please sign in to comment.