Skip to content

Add support to docker secrets #202

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

Merged
merged 4 commits into from
May 23, 2021
Merged

Add support to docker secrets #202

merged 4 commits into from
May 23, 2021

Conversation

ynuyasha
Copy link
Contributor

@ynuyasha ynuyasha commented May 6, 2021

Before submitting the PR, please make sure you do the following

  1. Contributor license agreement
    For us it's important to have the agreement of our contributors to use their work, whether it be code or documentation. Therefore, we are asking all contributors to sign a contributor license agreement (CLA) as commonly accepted in most open source projects. Just open the pull request and our CLA bot will prompt you briefly.

  2. Please check our contribution guidelines for some help in the process.

inspired from mysql docker_entrypoint
Add Support of docker secrets
@CLAassistant
Copy link

CLAassistant commented May 6, 2021

CLA assistant check
All committers have signed the CLA.

@evereq
Copy link
Member

evereq commented May 8, 2021

Hi @ynuyasha thank you for the PR.

It makes total sense for me.
The only thing I worry about a bit is that it's "inspired from MySQL docker_entrypoint" (https://github.com/docker-library/mysql/blob/master/5.6/docker-entrypoint.sh), which have a different license (GPL v2) to our (AGPL v3).
I will need to check that and if all is good, will merge PR.

@ynuyasha
Copy link
Contributor Author

ynuyasha commented May 8, 2021

Hi @evereq is a mix and match from mysql and this https://gist.github.com/bvis/b78c1e0841cfd2437f03e20c1ee059fe

@evereq
Copy link
Member

evereq commented May 8, 2021

@ynuyasha, unfortunately, it looks like the docker library for MySQL released under GPL v2 without a clause for "any later version" and so we can't include that code in AGPL v3 distribution according to what I understood. See https://softwareengineering.stackexchange.com/questions/267744/including-gplv2-code-in-gplv3-code.

They even added in the commit message: docker-library/mysql@7c7b508 "Upstream's license is complicated, but this gets us decent compatibility." :(

@ynuyasha
Copy link
Contributor Author

What you think if you open an issue about this on docker-library?
Because they suggest to use this approach inside documentation https://docs.docker.com/engine/swarm/secrets/#build-support-for-docker-secrets-into-your-images

@evereq
Copy link
Member

evereq commented May 12, 2021

@ynuyasha it's not about approach, it's only about reuse of code from other repos (projects). If you will implement it yourself or found some code that is MIT or GPL v3 licensed, we don't have a problem including it here. We just can't include GPL v2 ("only") code in our repos :)

@evereq
Copy link
Member

evereq commented May 12, 2021

Btw, @ynuyasha I don't think they will change the license from GPL v2 to "GPL v2 and any later version", even if we will ask, because "Upstream's license is complicated" :(

@ynuyasha
Copy link
Contributor Author

ynuyasha commented May 17, 2021

Hi @evereq , i have opened a question inside docker library docker-library/mysql#772 and they told me that you can include code into gpl3 and the same code is already redestribuite under other licences please read it

@evereq
Copy link
Member

evereq commented May 17, 2021

@ynuyasha think we can merge PR if you will tell that you copied that code from say https://github.com/docker-library/rabbitmq/blob/master/docker-entrypoint.sh released under MIT :)

Can you say that? And add please to the file docker-entrypoint.sh the following statement at the top of the file:

// Parts of the code in this file adapted from https://github.com/docker-library/rabbitmq/blob/master/docker-entrypoint.sh
// MIT License https://github.com/docker-library/rabbitmq/blob/master/LICENSE
// Copyright (c) 2014 Docker, Inc.

Thank you in advance ;)

this version works on /bin/sh
@ynuyasha
Copy link
Contributor Author

Hi @evereq i have changed a little bit, because i forgot that file_env function not working on /bin/sh shell, so is very strange that your test was green https://app.circleci.com/pipelines/github/ever-co/ever-traduora/437/workflows/b17852be-85a2-45c3-a465-ff3427d80d66/jobs/489, maybe is because not testing this feature?
With this new version is still valid mention rabbitmq work?

@evereq evereq merged commit bf4b802 into ever-co:develop May 23, 2021
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.

3 participants