https://github.com/ecodev/my-ichtus
myIchtus API and FE app
https://github.com/ecodev/my-ichtus
Last synced: 4 months ago
JSON representation
myIchtus API and FE app
- Host: GitHub
- URL: https://github.com/ecodev/my-ichtus
- Owner: Ecodev
- License: mit
- Created: 2018-10-19T13:43:30.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2025-10-07T00:43:07.000Z (4 months ago)
- Last Synced: 2025-10-07T02:38:51.889Z (4 months ago)
- Language: PHP
- Homepage:
- Size: 11.8 MB
- Stars: 2
- Watchers: 7
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# My Ichtus
[](https://github.com/ecodev/my-ichtus/actions)
[](https://scrutinizer-ci.com/g/Ecodev/my-ichtus/?branch=master)
[](https://scrutinizer-ci.com/g/Ecodev/my-ichtus/?branch=master)
## Introduction
My Ichtus is a web application based on GraphQL for the API and Angular for the client.
## Installation
The recommended way to get a working copy is the following:
1. Set up a nginx virtual host to point to `htdocs/` directory and to include `configuration/nginx.conf`
2. Create a database in MariaDB named "my-ichtus"
3. Configure database in `config/autoload/local.php` (see example `config/autoload/local.php.dist`)
4. Finally, build the app:
```sh
./bin/build.sh
```
## Development
### Server
To switch the API to development (to enable logging), run:
```sh
composer development-enable
```
Logs will be available in `logs/all.log`.
#### Configuration caching
When in development mode, the configuration cache is
disabled, and switching in and out of development mode will remove the
configuration cache.
You may need to clear the configuration cache in production when deploying if
you deploy to the same directory. You may do so using the following:
```sh
$ composer clear-config-cache
```
### Client
Run `yarn dev` for a dev server. Navigate to `http://my-ichtus.lan:4200/`. The app will
automatically reload if you change any of the source files.
## Testing
### PHPUnit
PHPUnit tests require a reference database dump. When the dump is loaded it **will destroy**
existing database. This must be done once before running tests. Then each test is ran
within a transaction which is rolled back, so the database state is always predictable.
To run PHPunit test:
```sh
./bin/load-test-data.php
./vendor/bin/phpunit # as many times as necessary
```
### Karma
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).