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

Add "Play with docker" integration #654

Open
trntv opened this issue Dec 24, 2018 · 4 comments
Open

Add "Play with docker" integration #654

trntv opened this issue Dec 24, 2018 · 4 comments
Milestone

Comments

@trntv
Copy link
Collaborator

trntv commented Dec 24, 2018

https://medium.com/@patternrecognizer/how-to-add-a-try-in-play-with-docker-button-to-your-github-project-41cb65721e94

@XzAeRo XzAeRo added this to the 3.2.0 milestone Jan 22, 2019
@alfredleo
Copy link
Contributor

Looking into that problem. For play with docker to work, all docker images and the code should be already inside containers. The containers should be compiled and pushed to https://hub.docker.com. So there should be constant docker images compilation to create containers with the current code, or compilation should be done per release. Correct me if I am wrong.

@XzAeRo
Copy link
Member

XzAeRo commented Feb 22, 2019

all docker images and the code should be already inside containers

correct

The containers should be compiled and pushed to https://hub.docker.com

not correct (at least not necessary), we could use a service like Gitlab too.

So there should be constant docker images compilation to create containers with the current code, or compilation should be done per release.

Yes and no. Yes, we should have image compilation (for testing and release purposes), but is not necessary for the Play With Docker (PWD) service.

Play with docker runs with docker-compose files, so there's no limitations in how we build the images. See this advanced PWD example file: https://raw.githubusercontent.com/vegasbrianc/prometheus/version-2/pwd-stack.yml and compare it to the "development" docker-compose file: https://raw.githubusercontent.com/vegasbrianc/prometheus/version-2/docker-compose.yml

Here's a diff comparing the files: https://www.diffchecker.com/r5A0IIME (left: docker-compose.yml, right: pwd-stack.yml), and you'll notice that the only differences are some volume naming changes, some defaults and most importantly, the source section, which dictates from where to fetch the data.

The problem with this is the time to test and try this stuff. If someone is willing to send a PR, I would be glad to review it.

alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 23, 2019
alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 23, 2019
alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 25, 2019
alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 25, 2019
alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 25, 2019
alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 25, 2019
alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 25, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
…at PWD runs composer install in background, so need to wait about 60 seconds for the application to start.
alfredleo added a commit to alfredleo/yii2-starter-kit that referenced this issue Feb 27, 2019
@alfredleo
Copy link
Contributor

alfredleo commented Feb 27, 2019

#676 Here is the PR.
You need to wait till composer install finishes in background for PWD. Watch for CPU to go less then 10%. It takes about 140 seconds to spin up after instance run. Squashed commit history.

alfredleo pushed a commit to alfredleo/yii2-starter-kit that referenced this issue Mar 12, 2019
@alfredleo
Copy link
Contributor

Will look at this once more when have some free time.

@XzAeRo XzAeRo mentioned this issue Apr 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants