Skip to content
This repository has been archived by the owner on Nov 20, 2020. It is now read-only.

Update a project #65

Open
allamand opened this issue Nov 9, 2016 · 11 comments
Open

Update a project #65

allamand opened this issue Nov 9, 2016 · 11 comments

Comments

@allamand
Copy link

allamand commented Nov 9, 2016

Hi @francescou,

Great works on this compose-ui!!
Do you have planed for an Edit Button for either Yaml file, Reame file (logo also should be nice)

I plan to use compose-ui to allow several dev teams to interract with a docker swarm cluster, and theses features would be great.

@francescou
Copy link
Owner

Hi @allamand

thank you very much :)

actually...I'm not sure if it would be useful a file editor inside the Compose UI.

It seems more interesting to me to manage all the files in a git repository and let the UI Load projects from a git repository

my team is using docker-compose-ui with gitlab to do so, this way we have version control and centralized authentication/authorization.

what do you think about this?

@allamand
Copy link
Author

allamand commented Nov 9, 2016

Thanks @francescou,

I'll give a try to the git workflow and let you know.

Do you activate create project from compose-ui in combination of git source for compose-projects ?

Sébastien

Le 9 nov. 2016 à 14:11, Francesco Uliana [email protected] a écrit :

Hi @allamand

thank you very much :)

actually...I'm not sure if it would be useful a file editor inside the Compose UI.

It seems more interesting to me to manage all the files in a git repository and let the UI Load projects from a git repository

my team is using docker-compose-ui with gitlab to do so, this way we have version control and centralized authentication/authorization.

what do you think about this?


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

@allamand
Copy link
Author

allamand commented Nov 9, 2016

@francescou I tried with GIT url but got an error :

Stack Compose UI
Recreating docker-compose-ui
Attaching to docker-compose-ui
docker-compose-ui | INFO:root:git repo: [email protected]:cloud/docker-compose-ui-projects.git
docker-compose-ui | INFO:root:git clone [email protected]:cloud/docker-compose-ui-projects.git
docker-compose-ui | Traceback (most recent call last):
docker-compose-ui |   File "/app/main.py", line 14, in <module>
docker-compose-ui |     from scripts.git_repo import git_pull, git_repo, GIT_YML_PATH
docker-compose-ui |   File "/app/scripts/git_repo.py", line 31, in <module>
docker-compose-ui |     Repo.clone_from(git_repo, GIT_YML_PATH)
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/repo/base.py", line 885, in clone_from
docker-compose-ui |     return cls._clone(git, url, to_path, GitCmdObjectDB, progress, **kwargs)
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/repo/base.py", line 831, in _clone
docker-compose-ui |     finalize_process(proc)
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/util.py", line 155, in finalize_process
docker-compose-ui |     proc.wait()
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/cmd.py", line 319, in wait
docker-compose-ui |     raise GitCommandError(self.args, status, self.proc.stderr.read())
docker-compose-ui | ValueError: I/O operation on closed file
docker-compose-ui exited with code 1

similar error with https endpoint instead of ssh

docker-compose-ui | INFO:root:git repo: https://gitlab.net/cloud/docker-compose-ui-projects.git
docker-compose-ui | INFO:root:git clone https://gitlab.net/cloud/docker-compose-ui-projects.git
docker-compose-ui | Traceback (most recent call last):
docker-compose-ui |   File "/app/main.py", line 14, in <module>
docker-compose-ui |     from scripts.git_repo import git_pull, git_repo, GIT_YML_PATH
docker-compose-ui |   File "/app/scripts/git_repo.py", line 31, in <module>
docker-compose-ui |     Repo.clone_from(git_repo, GIT_YML_PATH)
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/repo/base.py", line 885, in clone_from
docker-compose-ui |     return cls._clone(git, url, to_path, GitCmdObjectDB, progress, **kwargs)
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/repo/base.py", line 831, in _clone
docker-compose-ui |     finalize_process(proc)
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/util.py", line 155, in finalize_process
docker-compose-ui |     proc.wait()
docker-compose-ui |   File "/env/lib/python2.7/site-packages/git/cmd.py", line 319, in wait
docker-compose-ui |     raise GitCommandError(self.args, status, self.proc.stderr.read())
docker-compose-ui | ValueError: I/O operation on closed file

Do you have any idea how to debug ? (can't exec in the container)

@allamand
Copy link
Author

Hi,

my problem may be occur cause of self-signed certificates problem for my gitlab instance.

could we imagine allow to enable something like
git config --system http.sslverify false ?

@allamand
Copy link
Author

OK I Fix this by adding the env var GIT_SSL_NO_VERIFY when starting the container :

      GIT_REPO: https://gitlab.net/cloud/docker-compose-ui-projects.git
      GIT_SSL_NO_VERIFY: 1

This works for me I close the issue!

@allamand allamand reopened this Nov 10, 2016
@allamand
Copy link
Author

Sorry I reopen the thread I've got additional question :

Even with a git workflow for compose-projects I would like to enable "ephemeral" project creation for users to quickly create/test live conf on compose-ui, and when they are satisfied they can submit properly using git workflow.

It seams that project creation don't works with gitlab wlows actually ? When pushing new project I've got an error

@allamand
Copy link
Author

Hi,

In order to allow me to enable local update for testing purpose (letting know users that updates from UI is ephemeral and to backup thems they need to make a pull request in the compose-projects-repo) I update this in scripts/git_repo.py :

#GIT_YML_PATH = '/opt/docker-compose-projects-git/'
GIT_YML_PATH = '/opt/docker-compose-projects/'

This allow to have both git feature, and local update enabled.

What do you think about it ?

@francescou
Copy link
Owner

Hi @allamand and thanks for your contribution

if I understood correctly you don't want user to create ephemeral projects on the git repository, right?

@allamand
Copy link
Author

Hi @francescou,

No in fact that the opposite, even with git repo I would like users to be able to create test project

Sébastien

Le 16 nov. 2016 à 21:13, Francesco Uliana [email protected] a écrit :

Hi @allamand and thanks for your contribution

if I understood correctly you don't want user to create ephemeral projects on the git repository, right?


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

@francescou
Copy link
Owner

Hi, the problem is that it can be a bit confusing, using git, to create new project on docker-compose-ui and then not be able to push the modifications (the git repo is read-only).

We usually let the users create new projects on gitlab and then they can use them on docker-compose-ui once they've clicked "Reload projects" (it performs a git pull)

We also have an automated deployment pipeline (from git push to docker container deployment), I can write you an email if you are interested.

@allamand
Copy link
Author

I entirely agree with you!

But in my case I am promoting the use of docker swarm for many different teams with different working method, and as a first approach the use of gitlab and merge request may be overkill and I will loose to many people on the road.

I have change the path of directory in my fork so that both fit and local update are Woking with lot of WARNING in the réadme to remind users that if they want their project to persist they need to make pull request in gitlab.

Meanwhile they can easily play around using create button.

Yes please share your pipeline if you could ;)

Sébastien

Le 17 nov. 2016 à 07:43, Francesco Uliana [email protected] a écrit :

Hi, the problem is that it can be a bit confusing, using git, to create new project on docker-compose-ui and then not be able to push the modifications (the git repo is read-only).

We usually let the users create new projects on gitlab and then they can use them on docker-compose-ui once they've clicked "Reload projects" (it performs a git pull)

We also have an automated deployment pipeline (from git push to docker container deployment), I can write you an email if you are interested.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

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

No branches or pull requests

3 participants