Skip to content

itk-dev/aapodwalk_api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Aapodwalk api

See Production for information on how to deploy for production.

Development

Getting started:

docker compose pull
docker compose up --detach --remove-orphans
docker compose exec phpfpm composer install
docker compose exec phpfpm bin/console doctrine:migrations:migrate --no-interaction

Fixtures

docker compose exec phpfpm composer fixtures-load

If you run the fixtures, the following user will be available:

Username Password Roles API token
[email protected] password ROLE_ADMIN
[email protected] password ROLE_USER_ADMIN
[email protected] password ROLE_USER
[email protected] password ROLE_API this-is-not-a-very-secret-token

For creating more users, run the following command

docker compose exec phpfpm bin/console app:user:add EMAIL PASSWORD

Lint lint lint

docker compose exec phpfpm composer coding-standards-apply

Or perhaps:

docker compose exec phpfpm composer coding-standards-check

API

API documentation is available on /api/v1/docs:

open "http://$(docker compose port nginx 8080)/api/v1/docs"

A user must authenticate to actually use the API:

curl --header 'Authorization: Bearer this-is-not-a-very-secret-token' "http://$(docker compose port nginx 8080)/api/v1/routes"

Update api spec

docker compose exec phpfpm composer update-api-spec

Translations

Update translations

docker compose exec phpfpm composer update-translations

Update Danish translations (translations/*.da.xlf), e.g. using Poedit:

open translations/admin.da.xlf

To help the translation extractor find some translations, we have some translation expressions in templates/admin/_messages.html.twig.

Assets

We use Symfony's AssetMapper for asset management. Furthermore, as suggested by AssetMapper, we use BiomeJsBundle for linting assets.

See Serving Assets in dev vs prod for details on how to handle assets for the prod environment.

Apply and check coding standards for assets:

task coding-standards:assets:check

Commands

We use Console Commands for command in the console.

List the app commands with

task console -- list app

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •