dracoblue.net

Debugging Directus Serverside Extensions

You can find in the directus docs a good documentation how to run a build of directus in docker. For developing and contributing to direcuts itself there is a good documentation on running directus locally.

But if you want to develop a directus endpoint extension locally, you might want to use the "breakpoint" feature of your IDE (e.g. vscode). Without the need to run the entire directus stack with pnpm in development mode.

Continue reading ...

In directus, nodejs, vscode, vue by DracoBlue @ 19 Aug 2023 | 660 Words

VSCode 100% CPU Usage with WSL1

When I am using windows for development reasons in combination with wsl it is usually pretty good experience. As long as you don't try to mount a windows directory into the linux subsystem, but use the storage directly there - it's nice!

The official vscode extension for wsl usually integrates nicely with visual code.

But today I experienced a very bad performance of vscode and the windows system. A short htop / taskmanager call showed: All CPUs have been in use for 100%. The process eating all resource was called: .vscode-server.

Continue reading ...

In nodejs, vscode, windows, wsl by DracoBlue @ 22 Feb 2023 | 278 Words

Make symfony dotenv use putenv

The other day a friend of mine was using google-auth-library-php in combination with google-cloud-php-pubsub and wanted to set the path for the google credentials file via GOOGLE_APPLICATION_CREDENTIALS in .env.

So we figured that this did not work anymore in the newer version of dotenv (see commit in 4.3) the default value for use_putenv changed to false. And in symfony 5 there was a breaking change to switch use_putenv from true to false (see the putenv deprecation pull request.

Continue reading ...

In dotenv, gcloud, php, symfony by DracoBlue @ 16 Jan 2023 | 236 Words

Compiling newrelic php agent on mac m1 arm64

According to the arm64 newrelic php page there is arm64 support for the php agent, if it is running Amazon Linux or CentOS Linux8, but not for Apple or M1.

However, when I pulled the latest tar.gz (v10.4.0.316 as of 2023/01/13) at https://github.com/newrelic/newrelic-php-agent/archive/refs/tags/v10.4.0.316.tar.gz and tried to compile - it did nearly work.

The first tries of make agent, will fail with missing pcre_compile or aclocal or glibtoolize. This can be fixed by installing brew install pcre for pcre_compile, brew install automake for aclocal and brew install libtool for glibtoolize.

Then finally running make agent ends up in:

util_hash.c:198:5: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]
    case 2:
    ^
util_hash.c:198:5: note: insert '__attribute__((fallthrough));' to silence this warning
    case 2:
    ^
    __attribute__((fallthrough));
util_hash.c:198:5: note: insert 'break;' to avoid fall-through
    case 2:
    ^
    break;
Continue reading ...

In apple, arm, homebrew, newrelic, php by DracoBlue @ 14 Jan 2023 | 655 Words

Not working precedence of real environment variables in symfony dotenv

When configuring symfony with .env and real environment variables I ran into an interesting issue.

My first test drive of nginx unit (which is nice to not have a php-fpm+nginx docker container, but just one) I setup the php box and noticed that even though the Overriding Section states different, it seemed like my real environment variables did not have precedence in this case.

Continue reading ...

In nginx unit, php, symfony by DracoBlue @ 13 Sep 2022 | 198 Words

Page 1 - Page 2

Give something back

Were my blog posts useful to you? If you want to give back, support one of these charities, too!

Report hate in social media Campact e.V. With our technology and your help, we protect the oceans from plastic waste. Gesellschaft fur Freiheitsrechte e. V. The civil eye in the mediterranean

Recent Dev-Articles

Read recently

Recent Files

About