Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OPENPROJECT | Add openproject #1387

Merged
merged 7 commits into from
May 18, 2024
Merged

Conversation

baldarn
Copy link
Contributor

@baldarn baldarn commented May 9, 2024

I have the project of add openproject, so I added openproject to the project

XD

@baldarn
Copy link
Contributor Author

baldarn commented May 9, 2024

still WIP.

will have to test this and volumes configurations ;)

@baldarn
Copy link
Contributor Author

baldarn commented May 9, 2024

@alexbelgium I can't understand why Codacy Static Code Analysis is failing. why is that?

@alexbelgium
Copy link
Owner

Really nice thanks! I'm off for a couple days and will gladly help when I'll be back if needed!

@alexbelgium
Copy link
Owner

@alexbelgium I can't understand why Codacy Static Code Analysis is failing. why is that?

I think codacy is

@alexbelgium I can't understand why Codacy Static Code Analysis is failing. why is that?

Actually it is useless things that I have white listed on my own codacy but it seems it doesn't transfer to your checks... So you can just ignore it :)

@baldarn
Copy link
Contributor Author

baldarn commented May 14, 2024

the sad thing is that I can't try that. could we try and merge this to see if this is working if you thing everything is ok?

@baldarn baldarn marked this pull request as ready for review May 14, 2024 07:23
@alexbelgium
Copy link
Owner

Oh sorry I missed your message i'll merge right now!!

And thanks very much for the coffees on PayPal!

@alexbelgium alexbelgium merged commit 9e471cb into alexbelgium:master May 18, 2024
6 of 7 checks passed
@alexbelgium
Copy link
Owner

alexbelgium commented May 20, 2024

Hi! I've tested it but you miss an instruction to start the actual app : you should have a file in rootfs/etc/cont-init.d/99-run.sh that would contain the startup code

For the moment it just builds and executes the basic scripts but the app doesn't start. The best way to see what to put in the run.sh file is to check the entrypoint or cmd of the initial dockerfile

@alexbelgium
Copy link
Owner

@alexbelgium
Copy link
Owner

It actually is likely "exec /app/docker/prod/supervisord /app/docker/prod/entrypoint.sh" but then it says an error about file but found while starting

@alexbelgium
Copy link
Owner

You can troubleshoot and test by adding in the sh file of your /config either sleep infinity and then test commands from portainer console, or

#!/usr/bin/env bashio
# shellcheck shell=bash

echo "Starting"
#find / -name entrypoint.sh 2>/dev/null
#./docker/prod/entrypoint.sh

cp /app/docker/prod/supervisord /config/a
cp /app/docker/prod/entrypoint.sh /config/b

/./app/docker/prod/supervisord /app/docker/prod/entrypoint.sh

@baldarn
Copy link
Contributor Author

baldarn commented May 20, 2024

what if I remove the ENTRYPOINT [ "/ha_entrypoint.sh" ]?

what are the pro and cons?

@alexbelgium
Copy link
Owner

alexbelgium commented May 20, 2024

it all depends how is built the upstream container :

  • if it uses s6 supervision, then the line "ENV S6_STAGE2_HOOK=/ha_entrypoint.sh" will still make it execute
  • if it uses a simple system, then you can indeed use my custom entrypoint, and reference the previous entrypoing in a /etc/cont-init.d/run.sh file as I described
  • if the addon really needs the initial entrypoint to boot, then you can remove the line (as you wrote above) but execute the ha_entrypoint.sh as part of the initial entrypoint by using sed. Here is an example :
    RUN echo "wger ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers && \
    sed -i "1a sudo -E '/./ha_entrypoint.sh' || true" /home/wger/entrypoint.sh

For you it would be :
RUN sed -i "1a /./ha_entrypoint.sh" /app/docker/prod/entrypoint.sh

@alexbelgium
Copy link
Owner

btw if you want to launch yourself the building of a new addon version you can just open a new pull request with the changes and write /automerge in the comments

@baldarn
Copy link
Contributor Author

baldarn commented May 20, 2024

I will try with the third option and use the magic /automerge to see if something starts ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants