Unverified Commit 865d6781 authored by Giuseppe Carboni's avatar Giuseppe Carboni Committed by GitHub
Browse files

Merge pull request #924 from discos/centos_7_compatibility

Merging centos_7_compatibility into master
parents 251877a0 97f713ab
Loading
Loading
Loading
Loading
+85 −0
Original line number Original line Diff line number Diff line
name: DISCOS deployment and build

on:
  push:
  pull_request:

jobs:
  wait-for-download:
    name: Wait for any pending download
    runs-on: ubuntu-latest
    concurrency:
      group: download
      cancel-in-progress: false
    steps:
      - name: Go on with deployment
        run: true
  deploy-discos:
    name: Deploy DISCOS
    runs-on: ubuntu-latest
    needs: wait-for-download
    env:
      REPOSITORY_TOKEN: "${{ secrets.DEPENDENCIES_TOKEN }}"
      GH_TOKEN: "${{ secrets.GH_WORKFLOWS_TOKEN }}"
      GOOGLE_DRIVE_TOKEN: "${{ secrets.GOOGLE_DRIVE_TOKEN }}"
      PROVISIONED_VM_GDRIVE_ID: "${{ secrets.PROVISIONED_VM_GDRIVE_ID }}"
      PROVISIONED_ARCHIVE_GDRIVE_ID: "${{ secrets.PROVISIONED_ARCHIVE_GDRIVE_ID }}"
    strategy:
      fail-fast: false
      matrix:
        station: ['SRT', 'Medicina', 'Noto']
    steps:
      - name: Free up space
        uses: jlumbroso/free-disk-space@main
        with:
          tool-cache: true
      - name: Install Vagrant and VirtualBox
        run: |
          wget -O- https://apt.releases.hashicorp.com/gpg | sudo gpg --dearmor -o /usr/share/keyrings/hashicorp-archive-keyring.gpg
          echo "deb [signed-by=/usr/share/keyrings/hashicorp-archive-keyring.gpg] https://apt.releases.hashicorp.com $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/hashicorp.list
          sudo apt update && sudo apt install vagrant
          sudo apt install virtualbox
      - name: Set up Python
        uses: actions/setup-python@v5
        with:
          python-version: '3'
          check-latest: true
      - name: Clone the deployment repository
        uses: actions/checkout@v4
        with:
          repository: 'discos/deployment'
      - name: Install deployment package and dependencies
        run: |
          python -m pip install -r requirements.txt
          pip install .
      - name: Retrieve the VM from cache
        uses: actions/cache/restore@v4
        with:
          key: discos-manager-vm
          path: |
            /home/runner/discos_manager.ova
            /home/runner/vagrant.tar.gz
      - name: Install the virtual machine
        run: |
          vboxmanage import discos_manager.ova --vsys 0 --options keepallmacs
          rm discos_manager.ova
          tar -xzvf vagrant.tar.gz
        working-directory: /home/runner
      - name: Add the virtual machine to Vagrant
        run: |
          sed -i "s/$(cat id)/$(vboxmanage list vms | grep 'discos_manager' | grep -oP '(?<=\{)[0-9a-fA-F-]+(?=\})')/" action_provision
          sed -i "s/$(cat id)/$(vboxmanage list vms | grep 'discos_manager' | grep -oP '(?<=\{)[0-9a-fA-F-]+(?=\})')/" id
        working-directory: /home/runner/.deployment/.vagrant/machines/manager/virtualbox/
      - name: Set the branch name
        run: |
          if [ "${{ github.event_name }}" == "push" ]; then
            echo "BRANCH_NAME=${{ github.ref_name }}" >> $GITHUB_ENV
          elif [ "${{ github.event_name }}" == "pull_request" ]; then
            echo "BRANCH_NAME=${{ github.head_ref }}" >> $GITHUB_ENV
          fi
      - name: Deploy DISCOS
        run: |
          discos-deploy manager:development --deploy-only -s ${{ matrix.station }} -b ${{ env.BRANCH_NAME }}
      - name: Shutdown the virtual machine
        run: |
          discos-vms stop
+10 −0
Original line number Original line Diff line number Diff line
@@ -6,11 +6,13 @@ object/
*~
*~
*.swp
*.swp
*.pyc
*.pyc
.project*


# Ignore the SliLibrary directory
# Ignore the SliLibrary directory
Common/Libraries/SlaLibrary
Common/Libraries/SlaLibrary


# Files generated by the building process
# Files generated by the building process
Common/Interfaces/build.log
Common/Clients/CaltoolClient/src/calibrationtool_ui.py
Common/Clients/CaltoolClient/src/calibrationtool_ui.py
Common/Clients/CaltoolClient/src/calibrationtool_ui.pye
Common/Clients/CaltoolClient/src/calibrationtool_ui.pye
Common/Errors/AntennaErrors/idl/AntennaErrors.idl
Common/Errors/AntennaErrors/idl/AntennaErrors.idl
@@ -26,12 +28,16 @@ Common/Errors/ParserErrors/idl/ParserErrors.idl
Common/Errors/ReceiversErrors/idl/DerotatorErrors.idl
Common/Errors/ReceiversErrors/idl/DerotatorErrors.idl
Common/Errors/ReceiversErrors/idl/ReceiversErrors.idl
Common/Errors/ReceiversErrors/idl/ReceiversErrors.idl
Common/Errors/XBackendErrors/idl/XBackendsErrors.idl
Common/Errors/XBackendErrors/idl/XBackendsErrors.idl
Common/Errors/ActiveSurfaceErrors/idl/ASErrors.idl
Common/Interfaces/ActiveSurfaceInterface/idl/ActiveSurfaceCommon.idl
Common/Interfaces/AntennaInterface/idl/SolarSystemBody.idl
Common/Interfaces/AntennaInterface/idl/AntennaBoss.idl
Common/Interfaces/AntennaInterface/idl/AntennaBoss.idl
Common/Interfaces/AntennaInterface/idl/Moon.idl
Common/Interfaces/AntennaInterface/idl/Moon.idl
Common/Interfaces/AntennaInterface/idl/Mount.idl
Common/Interfaces/AntennaInterface/idl/Mount.idl
Common/Interfaces/AntennaInterface/idl/OTF.idl
Common/Interfaces/AntennaInterface/idl/OTF.idl
Common/Interfaces/AntennaInterface/idl/Observatory.idl
Common/Interfaces/AntennaInterface/idl/Observatory.idl
Common/Interfaces/AntennaInterface/idl/SkySource.idl
Common/Interfaces/AntennaInterface/idl/SkySource.idl
Common/Interfaces/AntennaInterface/idl/SolarSystemBody.idl
Common/Interfaces/ActiveSurfaceInterface/idl/ActiveSurfaceCommon.idl
Common/Interfaces/ActiveSurfaceInterface/idl/ActiveSurfaceCommon.idl
Common/Interfaces/CommonInterface/idl/AntennaDefinitions.idl
Common/Interfaces/CommonInterface/idl/AntennaDefinitions.idl
Common/Interfaces/CommonInterface/idl/BackendsDefinitions.idl
Common/Interfaces/CommonInterface/idl/BackendsDefinitions.idl
@@ -50,3 +56,7 @@ SRT/Clients/SRTActiveSurfaceGUIClient/include/SRTActiveSurfaceGUI.h
SRT/Clients/SRTActiveSurfaceGUIClient/src/moc_SRTActiveSurfaceCore.cpp
SRT/Clients/SRTActiveSurfaceGUIClient/src/moc_SRTActiveSurfaceCore.cpp
SRT/Clients/SRTActiveSurfaceGUIClient/src/moc_SRTActiveSurfaceGUIui.cpp
SRT/Clients/SRTActiveSurfaceGUIClient/src/moc_SRTActiveSurfaceGUIui.cpp
SRT/Interfaces/SRTActiveSurfaceInterface/idl/SRTActiveSurfaceBoss.idl
SRT/Interfaces/SRTActiveSurfaceInterface/idl/SRTActiveSurfaceBoss.idl
Common/Libraries/build.log
SRT/Interfaces/SRTActiveSurfaceInterface/idl/SRTActiveSurfaceCommon.idl
.DS_Store
.vscode/settings.json
+5 −0
Original line number Original line Diff line number Diff line
@@ -102,8 +102,13 @@ and this project adheres to [Semantic Versioning](http://semver.org/
                 The syntax for the command is the following: `enable=X;Y` with X and Y representing the 2 feeds the user would like to use for the Nodding observation.
                 The syntax for the command is the following: `enable=X;Y` with X and Y representing the 2 feeds the user would like to use for the Nodding observation.
                 This command must be placed in the <schedule_name>.bck file in order to work properly.
                 This command must be placed in the <schedule_name>.bck file in order to work properly.
    issue #619 - Active surface components are now capable of changing look-up tables on the fly via the `asSetLUT` command
    issue #619 - Active surface components are now capable of changing look-up tables on the fly via the `asSetLUT` command
    issue #806   Added support for the C-band receiver at the SRT
    project #2 - Completed integration of new SRT Minor Servos
    issue #2   - Completed integration of solar system planets, sun and moon tracking. Other bodies will be added in the future.


## Fixed
## Fixed
## Changed
## Changed
	issue #689 - The dataset provided by weather station has been enlarged by the wind direction. The correctponding RAL 'wx' command will noe provided wind direction readout, as well
	issue #689 - The dataset provided by weather station has been enlarged by the wind direction. The correctponding RAL 'wx' command will noe provided wind direction readout, as well
    issue #621 - The maximum number of chars of the schedule file name is now 37 (extension included). This is done for fits file and archive issue with the lenght of the schedule name.
    issue #621 - The maximum number of chars of the schedule file name is now 37 (extension included). This is done for fits file and archive issue with the lenght of the schedule name.
    issue #853 - The setSection command can now accept a wildcard (*) as section identifier. This will allow to configure all backend sections with a single command
    issue #895 - FitZilla version 1.23 released, the rest frequency is also added in the header of the Section table
 No newline at end of file
+44 −1
Original line number Original line Diff line number Diff line
@@ -162,6 +162,49 @@ void updateGenerator(maci::SimpleClient& client,Antenna::TGeneratorType& lastGen
				extraLabel6->Refresh();	
				extraLabel6->Refresh();	
				break;
				break;
			}
			}
			case Antenna::ANT_SOLARSYSTEMBODY : {
				IRA::CString str1,str2;
 
				Antenna::SolarSystemBodyAttributes_var att;
				Antenna::SolarSystemBody_var ssbody;
				try {
					ssbody=Antenna::SolarSystemBody::_narrow(lastGenerator);
					if (!CORBA::is_nil(ssbody)) {
						ssbody->getAttributes(att);
					}
				}
				catch (...) {
					_EXCPT(ClientErrors::UnknownExImpl,impl,"::Main()");
					_IRA_LOGGUARD_LOG_EXCEPTION(guard,impl,LM_ERROR);
					return;
				}			
				tmpString=(const char*)att->sourceID;
				outString="Source name    : "+tmpString;
				extraLabel1->setValue(outString);
				extraLabel1->Refresh();
				IRA::CIRATools::radToHourAngle(att->rightAscension,str1);
				IRA::CIRATools::radToSexagesimalAngle(att->declination,str2);
				outString="Apparent Eq.   : "+str1+"/"+str2+"/";
				str1.Format("%.5lf",att->julianEpoch);
				outString+=str1;
				extraLabel2->setValue(outString);
				extraLabel2->Refresh();
				IRA::CIRATools::radToAngle(att->gLongitude,str1);
				IRA::CIRATools::radToAngle(att->gLatitude,str2);
				outString="Galactic       : "+str1+"/"+str2;
				extraLabel3->setValue(outString);
				extraLabel4->Refresh();
				IRA::CIRATools::radToAngle(att->azimuth,str1);
				IRA::CIRATools::radToAngle(att->elevation,str2);
				outString="Horizontal     : "+str1+"/"+str2;
				extraLabel4->setValue(outString);
				extraLabel4->Refresh();								
				extraLabel5->setValue("");
				extraLabel5->Refresh();			
				extraLabel6->setValue("");
				extraLabel6->Refresh();	
				break;
			}
			case Antenna::ANT_OTF: {
			case Antenna::ANT_OTF: {
				Antenna::OTFAttributes_var att;
				Antenna::OTFAttributes_var att;
				Antenna::OTF_var otf;
				Antenna::OTF_var otf;
+14 −16
Original line number Original line Diff line number Diff line
@@ -6,6 +6,7 @@
#include <SkySourceC.h>
#include <SkySourceC.h>
#include <OTFC.h>
#include <OTFC.h>
#include <MoonC.h>
#include <MoonC.h>
#include <SolarSystemBodyC.h>
#include <ManagementErrors.h>
#include <ManagementErrors.h>
#include <acsncSimpleConsumer.h>
#include <acsncSimpleConsumer.h>
#include <fstream>
#include <fstream>
@@ -201,12 +202,7 @@ int main(int argc, char *argv[]) {
	// Change the style of the main frame 
	// Change the style of the main frame 
	window.setTitleStyle(CStyle(TITLE_COLOR_PAIR,TITLE_STYLE));
	window.setTitleStyle(CStyle(TITLE_COLOR_PAIR,TITLE_STYLE));
	
	
	if (window.colorReady()) {
	window.defineColor(GRAY_COLOR,500,500,500);
		window.defineColor(GRAY_COLOR,255,255,255);		
		window.defineColorPair(BLUE_GRAY,CColor::BLUE,GRAY_COLOR);
		window.defineColorPair(GRAY_BLUE,GRAY_COLOR,CColor::BLUE);		
	}
	else {
	window.defineColorPair(BLUE_GRAY,CColor::BLUE,CColor::WHITE);
	window.defineColorPair(BLUE_GRAY,CColor::BLUE,CColor::WHITE);
	window.defineColorPair(GRAY_BLUE,CColor::WHITE,CColor::BLUE);
	window.defineColorPair(GRAY_BLUE,CColor::WHITE,CColor::BLUE);
	window.defineColorPair(BLACK_RED,CColor::BLACK,CColor::RED);
	window.defineColorPair(BLACK_RED,CColor::BLACK,CColor::RED);
@@ -215,7 +211,7 @@ int main(int argc, char *argv[]) {
	window.defineColorPair(BLACK_BLUE,CColor::BLACK,CColor::BLUE);
	window.defineColorPair(BLACK_BLUE,CColor::BLACK,CColor::BLUE);
	window.defineColorPair(BLACK_MAGENTA,CColor::BLACK,CColor::MAGENTA);
	window.defineColorPair(BLACK_MAGENTA,CColor::BLACK,CColor::MAGENTA);
	window.defineColorPair(BLACK_WHITE,CColor::BLACK,CColor::WHITE);
	window.defineColorPair(BLACK_WHITE,CColor::BLACK,CColor::WHITE);
	}

	ACS_LOG(LM_FULL_INFO,MODULE_NAME"::Main()",(LM_INFO,MODULE_NAME"::FRAME_INITIALIZED"));
	ACS_LOG(LM_FULL_INFO,MODULE_NAME"::Main()",(LM_INFO,MODULE_NAME"::FRAME_INITIALIZED"));
	ACS_LOG(LM_FULL_INFO,MODULE_NAME"::Main()",(LM_INFO,MODULE_NAME"::GET_DEFAULT_COMPONENENT: %s",COMPONENT_INTERFACE_TPYE));
	ACS_LOG(LM_FULL_INFO,MODULE_NAME"::Main()",(LM_INFO,MODULE_NAME"::GET_DEFAULT_COMPONENENT: %s",COMPONENT_INTERFACE_TPYE));
	
	
@@ -401,7 +397,7 @@ int main(int argc, char *argv[]) {
		generatorType_box->setStatusLook(Antenna::ANT_SIDEREAL);
		generatorType_box->setStatusLook(Antenna::ANT_SIDEREAL);
		generatorType_box->setStatusLook(Antenna::ANT_MOON); 
		generatorType_box->setStatusLook(Antenna::ANT_MOON); 
		generatorType_box->setStatusLook(Antenna::ANT_SUN); 
		generatorType_box->setStatusLook(Antenna::ANT_SUN); 
		generatorType_box->setStatusLook(Antenna::ANT_SOLARSYTEMBODY); 
		generatorType_box->setStatusLook(Antenna::ANT_SOLARSYSTEMBODY); 
		generatorType_box->setStatusLook(Antenna::ANT_SATELLITE); 
		generatorType_box->setStatusLook(Antenna::ANT_SATELLITE); 
		generatorType_box->setStatusLook(Antenna::ANT_OTF); 
		generatorType_box->setStatusLook(Antenna::ANT_OTF); 
		
		
@@ -439,6 +435,8 @@ int main(int argc, char *argv[]) {
			_TW_SET_COMPONENT(output_label,0,WINDOW_HEIGHT-(OUTPUT_FIELD_HEIGHT+1),WINDOW_WIDTH-1,OUTPUT_FIELD_HEIGHT,OUTPUT_FIELD_COLOR_PAIR,OUTPUT_FIELD_STYLE,NULL);	
			_TW_SET_COMPONENT(output_label,0,WINDOW_HEIGHT-(OUTPUT_FIELD_HEIGHT+1),WINDOW_WIDTH-1,OUTPUT_FIELD_HEIGHT,OUTPUT_FIELD_COLOR_PAIR,OUTPUT_FIELD_STYLE,NULL);	
		#endif 
		#endif 
		
		
		
		
		// Monitors
		// Monitors
		ACS_LOG(LM_FULL_INFO,MODULE_NAME"::Main()",(LM_INFO,MODULE_NAME"::MONITORS_INSTALLATION"));
		ACS_LOG(LM_FULL_INFO,MODULE_NAME"::Main()",(LM_INFO,MODULE_NAME"::MONITORS_INSTALLATION"));
		/** Add all required monitor installation here */
		/** Add all required monitor installation here */
Loading