Browse Source

Maintenance: Adjust dev server command and update the developer manual.

Dusan Vuckovic 2 months ago
parent
commit
b350256d1c

+ 2 - 2
doc/developer_manual/development_environment/getting-started.md

@@ -116,10 +116,10 @@ features will not work.
 Zammad uses a [`Procfile`](https://devcenter.heroku.com/articles/procfile) to specify the different processes required by the application. We are using [**forego**](https://github.com/ddollar/forego)) to read the `Procfile` and spawn each process listed within it:
 
 ```sh
-$ forego start
+$ forego start -r
 ```
 
-Note that if any one of the managed processes spontaneously dies, `forego` will automatically kill the rest. Simply use  the `-r` flag to automatically respawn stopped processes instead.
+Note the `-r` switch which means that if any one of the services are gracefully stopped (e.g. due to a configuration change), `forego` will automatically respawn them for you.
 
 ### Manually
 

+ 1 - 1
doc/developer_manual/development_environment/how-to-set-up-a-development-environment.md

@@ -157,7 +157,7 @@ $ bundle install
 Zammad uses the gem `localhost` to automatically generate self-signed certificates. This will place `~/.local/state/localhost.rb/localhost.crt` and `~/.local/state/localhost.rb/localhost.key` files if needed. Then you can use one of the following commands to start the development server:
 
 ```sh
-$ VITE_RUBY_HOST=0.0.0.0 VITE_RUBY_HTTPS=true RAILS_ENV=development forego start -f Procfile.dev-https
+$ VITE_RUBY_HOST=0.0.0.0 VITE_RUBY_HTTPS=true RAILS_ENV=development forego start -r -f Procfile.dev-https
 # or
 $ pnpm dev:https
 ```

+ 2 - 2
package.json

@@ -3,8 +3,8 @@
   "scripts": {
     "generate-graphql-api": "bundle exec rails generate zammad:graphql_introspection > app/graphql/graphql_introspection.json && pnpm exec graphql-codegen -c .graphql_code_generator.js",
     "generate-setting-types": "bundle exec rails generate zammad:setting_types",
-    "dev": "RAILS_ENV=development forego start -f Procfile.dev",
-    "dev:https": "VITE_RUBY_HOST=0.0.0.0 VITE_RUBY_HTTPS=true RAILS_ENV=development forego start -f Procfile.dev-https",
+    "dev": "RAILS_ENV=development forego start -r -f Procfile.dev",
+    "dev:https": "VITE_RUBY_HOST=0.0.0.0 VITE_RUBY_HTTPS=true RAILS_ENV=development forego start -r -f Procfile.dev-https",
     "i18n": "rails generate zammad:translation_catalog",
     "lint": "pnpm lint:ts && pnpm lint:js && pnpm lint:css",
     "lint:fix": "pnpm lint:ts && pnpm lint:js:fix && pnpm lint:css:fix",