Download the PHP package polkovnik-z/docker-jobs-bundle without Composer
On this page you can find all versions of the php package polkovnik-z/docker-jobs-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download polkovnik-z/docker-jobs-bundle
More information about polkovnik-z/docker-jobs-bundle
Files in polkovnik-z/docker-jobs-bundle
Package docker-jobs-bundle
Short Description Symfony bundle that offers a batch processing system with Docker.
License MIT
Homepage https://github.com/polkovnik-z/docker-jobs-bundle
Informations about the package docker-jobs-bundle
Docker Jobs Bundle
Symfony bundle that offers a batch processing system with Docker.
Uses Docker containers to run and handle your jobs.
- Need to know
- Docker Configuration
- Installation
- Configuration
- Job Entity
- Bundle Configuration
- Next steps
- Console commands
- Job orchestration command
- Job submission command
- Stop job command
- Orphan job cleaning command
- Job Monitoring Dashboard
Need to know
All containers started by this bundle, are by default on the host's network.
So, if you need to connect to a local database, you can with the usual localhost|127.0.0.1
.
Docker configuration
Docker Engine API must be exposed on a local port in order to be able to connect.
1. Edit the docker.service
which by default on debian is located at /lib/systemd/system/docker.service
From this:
To this:
2. Edit /etc/docker/daemon.json
to expose docker api at 127.0.0.1:2375
Add hosts
to the json file as next:
3. Restart Docker completely
Docker Image
If not already done, you must create a Docker image which will be used to execute your jobs.
This bundle allows use of different images for each job but requires a default image to fallback on when no docker image is specified at launch.
Installation
When installing, you must specify the correct version of the bundle which coressponds to the Symfony version of your project.
Configuration
The configuration process is a bit lengthy, follow all the steps shown below.
- Job Entity
- Bundle Configuration
Job Entity
You must create your Job entity and extend of BaseJob class.
As long as you extend it of BaseJob
, the bundle will work correctly.
Bundle Configuration
Once you've got your Job entity and Docker image ready, the last step is to configure the bundle.
If not already done, include the bundle to your project:
Yaml configuration
At this point, you should have the bundle imported and working.
Next you need to configure the job orchestrating command to run non-stop.
Check out the steps below.
Next steps
-
Check out the Console commands to get the system up and running.
This step is vital to get the orchestration of job containers up and running. - Check out the Monitoring dashboard that you can activate if you wish.
License
- Review
All versions of docker-jobs-bundle with dependencies
symfony/asset Version ~5.0
symfony/translation Version ~5.0
symfony/form Version ~5.0