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

ojs cli install doesn't work in docker-compose.yml #52

Open
luisfelipe3d opened this issue Sep 17, 2021 · 6 comments
Open

ojs cli install doesn't work in docker-compose.yml #52

luisfelipe3d opened this issue Sep 17, 2021 · 6 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@luisfelipe3d
Copy link

Expected Behavior

When the environment variable OJS_CLI_INSTALL is changed to 1 on .env file, it is expected that the installation takes place automatically without the need of human interaction.

Current Behavior

After setting up the environment and running docker-compose, I verified that the configuration doesn't work. The following image illustrates the fact:
image

Steps to Reproduce

  1. Change directory to /versions/main/alpine/apache/php73/
  2. Set OJS_CLI_INSTALL to 1 on .env file
  3. In the docker-compose.yml file, uncomment lines 16,17 db and 35,36 ojs service
#     env_file:
#      - .env
  1. Run docker-composer -f docker-composer.yml up
  2. Access http://localhost:8081

Context (Environment)

More information about the host

$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux bookworm/sid
Release:        testing
Codename:       bookworm

$ uname -a
Linux alohomora 5.10.0-8-amd64 #1 SMP Debian 5.10.46-4 (2021-08-03) x86_64 GNU/Linux

$ docker -v
Docker version 20.10.5+dfsg1, build 55c4c88

$ docker-compose --version
docker-compose version 1.27.4, build unknown

Cheers,
Luis Leal.

@frafra
Copy link

frafra commented Oct 13, 2021

I can confirm that. config.inc.php is not populated correctly.

Are you upgrading?

@marcbria
Copy link
Collaborator

marcbria commented Nov 16, 2021

Sorry for the long silence.

About this specific issue: OJS lacks of a good client and the command-line installation is done via "curl" with some parameters.
I really don't trust much in this way of doing and I was never used in real life.

As far as this feature was never tested, this is considered an enhancement.
No time right now to work on this so PR are really welcome.

@marcbria marcbria added the enhancement New feature or request label Nov 16, 2021
@luisfelipe3d
Copy link
Author

I can confirm that. config.inc.php is not populated correctly.

Are you upgrading?

No, I used for development.

@matgn
Copy link

matgn commented Feb 1, 2022

Same here.
In logs :
[OJS CLI Install] First time running this container, preparing... [OJS CLI Install] Calling the install using pre-defined variables... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 curl: (7) Failed to connect to localhost port 80 after 0 ms: Connection refused

@matgn
Copy link

matgn commented Feb 1, 2022

I tried to force it with docker exec
https://github.com/pkp/docker-ojs/blob/main/templates/common/ojs/usr/local/bin/ojs-cli-install

it worked ...
Installation of OJS has completed successfully.

@marcbria
Copy link
Collaborator

marcbria commented Apr 10, 2022

As far as it can be accomplished with the frontend or the workaround posted by @matgn, is not a priority right now, but would be nice to adress this in the new version.

The real problem is the one posted at #179.

@marcbria marcbria added the bug Something isn't working label Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants