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

Ci/centos #696

Merged
merged 51 commits into from
Oct 18, 2023
Merged
Show file tree
Hide file tree
Changes from 50 commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
951fb37
Remove dependency to antares-study-updater
JasonMarechal25 Oct 9, 2023
5718745
New action
JasonMarechal25 Oct 9, 2023
0765264
Try fix centOS
JasonMarechal25 Oct 9, 2023
3781d60
3.6
JasonMarechal25 Oct 9, 2023
825d5a1
3.6
JasonMarechal25 Oct 9, 2023
b7a453c
Fix missing deps
JasonMarechal25 Oct 10, 2023
0ac00fb
Try simplify centOS image use
JasonMarechal25 Oct 9, 2023
3dc9649
Fix need
JasonMarechal25 Oct 9, 2023
828a499
Fix image name
JasonMarechal25 Oct 9, 2023
84a2a71
Update docker publish action
JasonMarechal25 Oct 9, 2023
599e961
Properly source bashrc in actions
JasonMarechal25 Oct 9, 2023
a928f54
test
JasonMarechal25 Oct 9, 2023
0322d37
yml
JasonMarechal25 Oct 9, 2023
b0cad9a
Add -l
JasonMarechal25 Oct 9, 2023
8f836e4
f
JasonMarechal25 Oct 9, 2023
b63e363
f
JasonMarechal25 Oct 9, 2023
1a5699c
source
JasonMarechal25 Oct 9, 2023
ccfa9d9
source
JasonMarechal25 Oct 9, 2023
72e6ab0
shell
JasonMarechal25 Oct 9, 2023
30251c4
Proper git
JasonMarechal25 Oct 9, 2023
34d6e22
Fix action
JasonMarechal25 Oct 10, 2023
d14d7b9
Add wheel package
JasonMarechal25 Oct 10, 2023
ca79148
Add wheel package
JasonMarechal25 Oct 10, 2023
7073eb7
Install python3
JasonMarechal25 Oct 10, 2023
de7eab9
Fix install deps
JasonMarechal25 Oct 10, 2023
30f7322
Install cmake
JasonMarechal25 Oct 10, 2023
138b1e8
source devtoolset9
JasonMarechal25 Oct 10, 2023
efe8c6a
Fix missing deps
JasonMarechal25 Oct 10, 2023
9728de5
Fix rebase
JasonMarechal25 Oct 10, 2023
10f4c4b
Revert "Fix missing deps"
JasonMarechal25 Oct 10, 2023
47dc03b
Delete test action
JasonMarechal25 Oct 10, 2023
55cebe3
Fix missing cache
JasonMarechal25 Oct 10, 2023
fcf7864
f
JasonMarechal25 Oct 10, 2023
b9564f4
Fix ubuntu CI
JasonMarechal25 Oct 12, 2023
37e45c9
Fix ubuntu CI
JasonMarechal25 Oct 12, 2023
b08a400
Fix ubuntu CI
JasonMarechal25 Oct 12, 2023
c98863c
Fix ubuntu CI
JasonMarechal25 Oct 12, 2023
f1912bc
Fix ubuntu CI
JasonMarechal25 Oct 13, 2023
e63894f
Fix ubuntu CI
JasonMarechal25 Oct 13, 2023
630170e
Fix ubuntu CI
JasonMarechal25 Oct 13, 2023
16bcdcf
Fix ubuntu CI
JasonMarechal25 Oct 13, 2023
12d88ce
Fix ubuntu CI
JasonMarechal25 Oct 13, 2023
fdf7f2b
Fix ubuntu CI
JasonMarechal25 Oct 13, 2023
096b7b9
Fix centOS
JasonMarechal25 Oct 13, 2023
98b15b3
Fix centOS
JasonMarechal25 Oct 13, 2023
5e4e234
Build TBB
JasonMarechal25 Oct 13, 2023
cbce444
Build TBB
JasonMarechal25 Oct 13, 2023
b3859b2
Build boost test
JasonMarechal25 Oct 13, 2023
463ef43
$
JasonMarechal25 Oct 13, 2023
acc6728
Fix ci
JasonMarechal25 Oct 13, 2023
fa73a3a
Reactivate build UI to catch dep issues
JasonMarechal25 Oct 18, 2023
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
17 changes: 12 additions & 5 deletions .github/workflows/build_centos7.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,20 +25,20 @@ jobs:
uses: tj-actions/changed-files@v32
with:
files: |
docker/centos7-bare
docker/centos7-system-deps

- name: Docker file push
id: docker_push
if: steps.changed-files.outputs.any_changed == 'true'
uses: elgohr/Publish-Docker-Github-Action@master
uses: elgohr/Publish-Docker-Github-Action@main
with:
name: antaresrte/rte-antares
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
workdir: docker
dockerfile: centos7-bare
dockerfile: centos7-system-deps
cache: false
tags: centos7-xpansion-bare
tags: centos7-system-deps

versions:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -72,7 +72,7 @@ jobs:
build:
runs-on: ubuntu-latest
needs: [ docker_publish, versions ]
container: 'antaresrte/rte-antares:centos7-xpansion-bare'
container: 'antaresrte/rte-antares:centos7-system-deps'
strategy:
matrix:
xprs: [ XPRESS-ON, XPRESS-OFF ]
Expand Down Expand Up @@ -117,8 +117,15 @@ jobs:
with:
prefix: "../rte-antares-deps-Release/"

- name: Compile tbb
uses: ./.github/workflows/compile-tbb
with:
cmake: 'cmake3'

- name: Install dependencies
run: |
pip3 install --upgrade pip
pip3 install wheel #Does not work in requirements
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is wheel a new dependency? why ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

¯_(ツ)_/¯

pip3 install -r requirements-tests.txt
pip3 install -r requirements-ui.txt
- name: Configure
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/build_ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,7 @@ jobs:
- name: Install mandatory system libraries
run: |
sudo apt-get update --fix-missing
sudo apt-get install libjsoncpp-dev libgtest-dev libboost-mpi-dev libboost-program-options-dev libtbb-dev
cd /usr/src/googletest/
sudo cmake .
sudo cmake --build .
sudo apt-get install -y ccache cmake libgtest-dev libjsoncpp-dev libtbb-dev libopenmpi-dev

- name: Read antares-solver version
id: antares-version
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ jobs:
shell: bash

- name: Compile tbb
uses: ./.github/workflows/compile-tbb
uses: ./.github/workflows/compile-tbb
with:
cmake: 'cmake'
cmake: 'cmake'

- name: Download pre-compiled librairies
uses: ./.github/workflows/download-extract-precompiled-libraries-zip
Expand Down
17 changes: 12 additions & 5 deletions .github/workflows/centos-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,20 @@ jobs:
uses: tj-actions/changed-files@v32
with:
files: |
docker/centos7-bare
docker/centos7-system-deps

- name: Docker file push
id: docker_push
if: steps.changed-files.outputs.any_changed == 'true'
uses: elgohr/Publish-Docker-Github-Action@master
uses: elgohr/Publish-Docker-Github-Action@main
with:
name: antaresrte/rte-antares
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
workdir: docker
dockerfile: centos7-bare
dockerfile: centos7-system-deps
cache: false
tags: centos7-xpansion-bare
tags: centos7-system-deps

userguide:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -107,7 +107,7 @@ jobs:
build:
runs-on: ubuntu-latest
needs: [ docker_publish, userguide, versions ]
container: 'antaresrte/rte-antares:centos7-xpansion-bare'
container: 'antaresrte/rte-antares:centos7-system-deps'
strategy:
matrix:
xprs: [ XPRESS-ON, XPRESS-OFF ]
Expand Down Expand Up @@ -144,8 +144,15 @@ jobs:
with:
prefix: "../rte-antares-deps-Release/"

- name: Compile tbb
uses: ./.github/workflows/compile-tbb
with:
cmake: 'cmake3'

- name: Install dependencies
run: |
pip3 install --upgrade pip
pip3 install wheel #Does not work in requirements
pip3 install -r requirements-tests.txt
pip3 install -r requirements-ui.txt

Expand Down
67 changes: 40 additions & 27 deletions .github/workflows/centos7-system-deps-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,31 @@ on:
- release/*
- ci/*
jobs:
docker_publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
with:
fetch-depth: 0
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v32
with:
files: |
docker/centos7-system-deps

- name: Docker file push
id: docker_push
if: steps.changed-files.outputs.any_changed == 'true'
uses: elgohr/Publish-Docker-Github-Action@main
with:
name: antaresrte/rte-antares
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
workdir: docker
dockerfile: centos7-system-deps
cache: false
tags: centos7-system-deps

versions:
runs-on: ubuntu-latest
Expand All @@ -16,7 +41,7 @@ jobs:
antares-xpansion-version: ${{steps.antares-xpansion-version.outputs.result}}
antares-deps-version: ${{steps.antares-deps-version.outputs.result}}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v3.6.0
- name: Read antares-solver version
id: antares-version
uses: ./.github/actions/read-json-value
Expand All @@ -41,40 +66,21 @@ jobs:
build:

runs-on: ubuntu-latest
needs: versions
container: 'centos:7'
needs: [ docker_publish, versions ]
container: 'antaresrte/rte-antares:centos7-system-deps'

steps:
- id: branch-name
uses: tj-actions/branch-names@v6

- name: Set up Python
run: |
yum update -y
yum install -y python3 python3-pip
pip3 install --upgrade pip

- name: Install libraries
run: |
yum install -y wget git epel-release redhat-lsb-core gcc gcc-c++ make centos-release-scl scl-utils
yum install -y jsoncpp-devel gtest-devel openmpi-devel doxygen graphviz boost-program-options
yum install -y cmake3 devtoolset-9 environment-modules rpm-build zlib-devel
yum install -y rh-git227-git
yum install -y libuuid-devel

- name: update bashrc
run: |
echo "source scl_source enable rh-git227" >> ~/.bashrc
echo "source scl_source enable devtoolset-9" >> ~/.bashrc

- uses: actions/checkout@v3
- uses: actions/[email protected]
with:
submodules: true

- name: Install dependencies
run: |
pip3 install wheel #Does not work in requirements
pip3 install -r requirements-tests.txt
pip3 install -r requirements-ui.txt

- name: Compile Boost
uses: ./.github/workflows/compile-boost
Expand All @@ -86,19 +92,26 @@ jobs:
with:
cmake: 'cmake3'

- name: Setup cmake
uses: jwlawson/[email protected]
with:
cmake-version: '3.22.x'

- name: Configure
run: |
source /opt/rh/devtoolset-9/enable
export LD_LIBRARY_PATH=/usr/lib64/openmpi/lib:$LD_LIBRARY_PATH
export PATH=/usr/lib64/openmpi/bin:$PATH
cmake3 -B _build -S . \
cmake -B _build -S . \
a-zakir marked this conversation as resolved.
Show resolved Hide resolved
-DDEPS_INSTALL_DIR=rte-antares-deps-Release \
-DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=_install -DBUILD_UI=ON -DALLOW_RUN_AS_ROOT=ON
-DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=_install -DBUILD_UI=OFF -DALLOW_RUN_AS_ROOT=ON
JasonMarechal25 marked this conversation as resolved.
Show resolved Hide resolved

- name: Build
run: |
source /opt/rh/devtoolset-9/enable
export LD_LIBRARY_PATH=/usr/lib64/openmpi/lib:$LD_LIBRARY_PATH
export PATH=/usr/lib64/openmpi/bin:$PATH
cmake3 --build _build --config Release -j2 --target install
cmake --build _build --config Release -j2 --target install
JasonMarechal25 marked this conversation as resolved.
Show resolved Hide resolved

- name: Running unit tests
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/publish_centos_docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ jobs:

- name: Docker file push
id: docker_push
uses: elgohr/Publish-Docker-Github-Action@master
uses: elgohr/Publish-Docker-Github-Action@main
with:
name: antaresrte/rte-antares
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
workdir: docker
dockerfile: centos7-bare
dockerfile: centos7-system-deps
cache: false
tags: centos7-xpansion-bare
tags: centos7-system-deps
6 changes: 3 additions & 3 deletions .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,12 @@ jobs:
os: ${{matrix.os}}
os-full-name: Ubuntu-20.04
buildtype: Debug

- name: Compile Boost
uses: ./.github/workflows/compile-boost
with:
with:
prefix: "../rte-antares-deps-Release/"


- name: Init submodule
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/ubuntu-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,12 +127,12 @@ jobs:
antares-version: ${{steps.antares-version.outputs.result}}
os: ${{matrix.os}}
os-full-name: Ubuntu-20.04

- name: Compile Boost
uses: ./.github/workflows/compile-boost
with:
with:
prefix: "../rte-antares-deps-Release/"

- name: Download userguide
uses: actions/download-artifact@v3
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/windows-vcpkg-deps-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ jobs:
shell: bash

- name: Compile tbb
uses: ./.github/workflows/compile-tbb
uses: ./.github/workflows/compile-tbb
with:
cmake: 'cmake'
cmake: 'cmake'

- name: Configure
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/windows-vcpkg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,10 @@ jobs:
shell: bash

- name: Compile tbb
uses: ./.github/workflows/compile-tbb
uses: ./.github/workflows/compile-tbb
with:
cmake: 'cmake'
cmake: 'cmake'

- name: Download pre-compiled librairies
uses: ./.github/workflows/download-extract-precompiled-libraries-zip
with:
Expand Down
18 changes: 9 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -349,20 +349,20 @@ install(DIRECTORY ${ANTARES_SOLVER_DIR}/../lib/

install(PROGRAMS ${ANTARES_SOLVER_PATH}
TYPE BIN)

find_package(antares-study-updater)
if (antares-study-updater_FOUND)

if (${CMAKE_BUILD_TYPE} STREQUAL "Release")
get_target_property( ANTARES_STUDY_UPDATER_PATH antares-${ANTARES_VERSION}-study-updater IMPORTED_LOCATION_RELEASE )
else()
get_target_property( ANTARES_STUDY_UPDATER_PATH antares-${ANTARES_VERSION}-study-updater IMPORTED_LOCATION_DEBUG )
endif()
if (${CMAKE_BUILD_TYPE} STREQUAL "Release")
get_target_property(ANTARES_STUDY_UPDATER_PATH antares-${ANTARES_VERSION}-study-updater IMPORTED_LOCATION_RELEASE)
else ()
get_target_property(ANTARES_STUDY_UPDATER_PATH antares-${ANTARES_VERSION}-study-updater IMPORTED_LOCATION_DEBUG)
endif ()

install(PROGRAMS ${ANTARES_STUDY_UPDATER_PATH}
TYPE BIN)
endif()
TYPE BIN)

endif ()

include (InstallRequiredSystemLibraries)

Expand Down
46 changes: 0 additions & 46 deletions docker/centos7

This file was deleted.

Loading
Loading