citizen-intelligence-agency/src/site/apt/index.apt

Summary

Maintainability
Test Coverage
Citizen Intelligence Agency

  The Citizen Intelligence Agency is a volunteer-driven, open-source intelligence (OSINT) project focusing on political activity in Sweden. By monitoring key political figures and institutions, the platform provides valuable insights into financial performance, risk metrics, and political trends. The dashboard features a ranking system, enabling users to objectively compare politicians based on performance. The initiative is independent and non-partisan, seeking to encourage informed decision-making, enhance transparency in governance, and cultivate an engaged and well-informed citizenry.

Section: About Hack23

  * Website: {{http://www.hack23.com}}.
  
  * LinkedIn: {{http://www.linkedin.com/in/jamessorling}}.

Data Sources

  The project relies on open data from various sources, including:

  * {{http://data.riksdagen.se/}}. Offers a wide range of data related to the Swedish Parliament, including members, committees, and documents.
  
  * {{http://www.val.se/}}. Provides information on election processes, results, and political parties in Sweden.
  
  * {{http://data.worldbank.org/}}. Contains global development data, including economic indicators and demographic information.
  
  * {{https://www.esv.se/}}. Offers data on government finances, economic trends, and public sector operations in Sweden.

Badges

[https://img.shields.io/github/license/Hack23/cia.svg]

[https://app.fossa.io/api/projects/git%2Bgithub.com%2FHack23%2Fcia.svg?type=shield]  

[https://cla-assistant.io/readme/badge/Hack23/cia]

[https://img.shields.io/maven-central/v/com.hack23.cia/cia-dist-deb.svg]

[https://bestpractices.coreinfrastructure.org/projects/770/badge]

[https://api.securityscorecards.dev/projects/github.com/Hack23/cia/badge]

[https://www.codefactor.io/repository/github/hack23/cia/badge]

[https://api.codeclimate.com/v1/badges/14cc2db98322e8338ef1/maintainability]

[https://codebeat.co/badges/5a7cf18f-68cb-4535-b197-8b541bf9bb7c]

[https://depshield.sonatype.org/badges/Hack23/cia/depshield.svg]

[http://isitmaintained.com/badge/resolution/Hack23/cia.svg]

[http://isitmaintained.com/badge/open/Hack23/cia.svg]
  

Runtime (JDK 21+)

[https://img.shields.io/badge/jdk-21-green.svg]

[https://img.shields.io/badge/jdk-22-orange.svg]

Section: Resources

  * Project Documentation {{http://hack23.github.io/cia/}}.
  
  * Project Architecture {{http://hack23.github.io/cia/architecture.html}}. - Delve into the architecture of the Citizen Intelligence Agency. This overview provides a look at the enterprise context, system context, system containers, web application components, deployment strategy, and AWS account structure of the project.
  
  * Entity Model {{https://hack23.github.io/cia/service.data.impl/hbm2doc/entities/index.html}}. - Explore our Entity Model, which provides a detailed look at the entities in our system and their relationships. This page is particularly useful for understanding the data structure of our project.
  
  * API Docs {{https://hack23.github.io/cia/apidocs/index.html}}. - Access the API documentation for the Citizen Intelligence Agency project. This documentation provides a detailed view of the various packages within the system, helping developers understand and work with the project's API.


Running docker image
  
 Docker repository : https://hub.docker.com/r/hack23/cia/ 

 1. docker run hack23/cia:2022.12.26 -p 28443:8443

 2. Access server at https://localhost:28443/cia/ , register new user to get admin access


Installing Debian/Ubuntu package

 Currently only build a debian package, works with debian and ubuntu 18.04+


 Installing database(postgres) and openjdk

 $ sudo apt-get install openjdk-16-jdk postgresql-13 pgadmin3

 2.1 Installing Postgresql on Ubuntu

 $ sudo apt-get install postgresql-13 postgresql-contrib postgresql-13-pgaudit

 3. Create empty database

 Below description set the default username/password and database name used for development, recommend using custom credentials and update the configuration at /opt/cia/webapps/cia/WEB-INF/database.properties to define your own username/password and database name.

 $ sudo su - postgres
 $ psql
 postgres=# CREATE USER eris WITH password 'discord';
 postgres=# CREATE DATABASE cia_dev;
 postgres=# GRANT ALL PRIVILEGES ON DATABASE cia_dev to eris;

 4. Modify postgres setting, enable prepared transactions

 Edit file "/etc/postgresql/13/main/postgresql.conf" set

 max_prepared_transactions = 100
 shared_preload_libraries = 'pg_stat_statements, pgaudit, pgcrypto'
 pgaudit.log = ddl
 pg_stat_statements.track = all
 pg_stat_statements.max = 10000


 5. Modify postgres setting
 Edit file "/etc/postgresql/13/main/pg_hba.conf" add line

 host all all ::1/128 md5


 6. Restart postgres

 $ service postgresql restart

 7. Get cia debian package and

 $ wget https://oss.sonatype.org/content/repositories/releases/com/hack23/cia/cia-dist-deb/2022.12.26/cia-dist-deb-2022.12.26.deb

 8. Install debian package

 $ sudo dpkg -i cia-dist-deb-2022.12.26.deb


 9. Access the server at {{{https://localhost:28443/cia/}https://localhost:28443/cia/}}