Trouble setting up workflow automation tool on cloud platform

Hey everyone, I’m struggling to get a workflow automation tool running on a popular cloud platform. I’ve tried using Docker but I’m hitting a wall. Could use some help!

I set up the database like this:

cloudplatform extras:add cloudplatform-postgres:basic-tier --version=11 -a myproject

My Dockerfile is super simple:

FROM workflowtool/workflowtool

And here’s my config file:

setup:
  config:
    APP_NAME: "myproject"
    PLATFORM_DOMAIN: "cloudapp.com"
    NODE_ENV: "production"
    TIMEZONE: "Europe/Paris"
    APP_URL: "${APP_NAME}.${PLATFORM_DOMAIN}"
    APP_PORT: "${PORT}"
    SECURITY_KEY: "mysecretkey123"
    DATABASE_TYPE: "postgres"
    DATABASE_HOST: "dbserver"
    DATABASE_NAME: "mydb"
    DATABASE_PORT: 5432
    DATABASE_USER: "dbadmin"
    DATABASE_PASSWORD: "dbsecret"

build:
  docker:
    web: Dockerfile

When I check the logs, I see this:

[WARNING] App not running as main process
Zombie cleanup might not work properly
Fix: Use -s flag or set CLEANUP_VAR to register as subprocess manager

su-exec: setgroups: Operation not allowed
App crashed - H10 error

Any ideas what I’m doing wrong? Thanks in advance!

hey there! looks like ur having some trouble with permissions and port binding. have u tried setting the CLEANUP_VAR env variable? that might help with the zombie process issue. also, double-check ur dockerfile to make sure its running as the right user. good luck!

I’ve dealt with similar issues before, and it can be frustrating. From what I see, the main problem seems to be how your container is handling permissions and process management. Here’s what worked for me:

  1. Modify your Dockerfile to explicitly set the user:
FROM workflowtool/workflowtool
USER root
RUN groupadd -r appuser && useradd -r -g appuser appuser
USER appuser
  1. In your config file, add these environment variables:
CLEANUP_VAR: 'true'
PORT: '${PORT:-5000}'
  1. Make sure your app listens on 0.0.0.0 instead of localhost.

These changes should address the permission issues and ensure your app binds to the correct port. Let me know if you need more help!

Your error message suggests a couple of potential issues. The application’s failure to bind to the expected port may be linked to incorrect environment variable settings, meaning the app might not be listening on the port provided by the cloud platform. In addition, the su-exec error implies there could be a permission problem with how the container is running. I suggest reviewing your Dockerfile to ensure the container is running as the correct user and verifying that your process is configured to use the PORT environment variable. This should help in resolving both the binding and permission issues.