You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by pdion891 <gi...@git.apache.org> on 2015/10/05 00:36:26 UTC

[GitHub] cloudstack pull request: Dockerfile part2

GitHub user pdion891 opened a pull request:

    https://github.com/apache/cloudstack/pull/910

    Dockerfile part2

    This PR simplify download of systemvm templates, work with docker-compose and enable integration-api port and use of localstorage without reconfiguration of cloudstack.
    
    Thanks


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/pdion891/cloudstack dockerfile5

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cloudstack/pull/910.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #910
    
----
commit 655eae8f17f9fbd49924ad0f8e760f770e7d5955
Author: Pierre-Luc Dion <pd...@apache.org>
Date:   2015-10-04T22:32:47Z

    allow download of systemvm template, work with docker-compose, enable integration-api port automatically

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by runseb <gi...@git.apache.org>.
Github user runseb commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41119897
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    not  a big fan of this, you are assuming XS host...


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by runseb <gi...@git.apache.org>.
Github user runseb commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41171391
  
    --- Diff: tools/docker/init.sh_centos6 ---
    @@ -17,27 +17,35 @@
     # under the License.
     #
     # update database connection
    +# /usr/bin/cloudstack-setup-databases cloud:password@$MYSQL_PORT_3306_TCP_ADDR
     # start cloudstack-management server
    -#/usr/bin/cloudstack-setup-databases cloud:password@$MYSQL_PORT_3306_TCP_ADDR
     
     # initial startup of the container to generage ssh_key
     # performed as privileged
     if [ ! -d /var/cloudstack/management/.ssh ]; then
     	mknod /dev/loop6 -m0660 b 7 6
     fi
    -sleep 5
     
    -mysql -p"$MYSQL_ENV_MYSQL_ROOT_PASSWORD" -h"$MYSQL_PORT_3306_TCP_ADDR" \
    +RESTART_REQUIRED=false
    +
    +until nc -z $MYSQL_PORT_3306_TCP_ADDR 3306; do
    --- End diff --
    
    that would be good. giving a hint that the link is probably not there or not set properly....that's why the env does not exist


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by runseb <gi...@git.apache.org>.
Github user runseb commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41120457
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    yeah, fine with me. seems odd but it's helping.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by runseb <gi...@git.apache.org>.
Github user runseb commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41171193
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    I am happy with vhd-util now. that we we can have the same image for XS and KVM.
    and yes, a separate dockgrfile for noredis setup would be great.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by milamberspace <gi...@git.apache.org>.
Github user milamberspace commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41616136
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    Perhaps instead of theses 2 last lines:
    wget -O /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver/vhd-util http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    (one line)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by pdion891 <gi...@git.apache.org>.
Github user pdion891 closed the pull request at:

    https://github.com/apache/cloudstack/pull/910


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by terbolous <gi...@git.apache.org>.
Github user terbolous commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41142674
  
    --- Diff: tools/docker/init.sh_centos6 ---
    @@ -17,27 +17,35 @@
     # under the License.
     #
     # update database connection
    +# /usr/bin/cloudstack-setup-databases cloud:password@$MYSQL_PORT_3306_TCP_ADDR
     # start cloudstack-management server
    -#/usr/bin/cloudstack-setup-databases cloud:password@$MYSQL_PORT_3306_TCP_ADDR
     
     # initial startup of the container to generage ssh_key
     # performed as privileged
     if [ ! -d /var/cloudstack/management/.ssh ]; then
     	mknod /dev/loop6 -m0660 b 7 6
     fi
    -sleep 5
     
    -mysql -p"$MYSQL_ENV_MYSQL_ROOT_PASSWORD" -h"$MYSQL_PORT_3306_TCP_ADDR" \
    +RESTART_REQUIRED=false
    +
    +until nc -z $MYSQL_PORT_3306_TCP_ADDR 3306; do
    --- End diff --
    
    If the environment variable is missing this will loop like this:
    eriweb@ubuntu-docker:~/git/cloudstack/tools/docker pr/910$ docker run -ti cloudstack/management_centos6
    usage: nc [-46DdhklnrStUuvzC] [-i interval] [-p source_port]
    	  [-s source_ip_address] [-T ToS] [-w timeout] [-X proxy_version]
    	  [-x proxy_address[:port]] [hostname] [port[s]]
    waiting for mysql-server...
    usage: nc [-46DdhklnrStUuvzC] [-i interval] [-p source_port]
    	  [-s source_ip_address] [-T ToS] [-w timeout] [-X proxy_version]
    	  [-x proxy_address[:port]] [hostname] [port[s]]
    waiting for mysql-server...
    
    Perhaps we should add a check for required variables and fail if they are not present?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by terbolous <gi...@git.apache.org>.
Github user terbolous commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41120279
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    I wouldn't say assuming, more like facilitating for a XS host. We know that vhd-util is a requirement for XS, imho it is better to bundle it than adding a manual "oh, remember to install vhd-util first" note.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by runseb <gi...@git.apache.org>.
Github user runseb commented on the pull request:

    https://github.com/apache/cloudstack/pull/910#issuecomment-145461959
  
    aside of the vhd-util download, +1 LGTM based on code review.
    Does not impact cloudstack core


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by terbolous <gi...@git.apache.org>.
Github user terbolous commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41121330
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    fwiw, I don't believe it is needed on XS 6.5+, so give it some time and we can remove it again :-)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by pdion891 <gi...@git.apache.org>.
Github user pdion891 commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/910#discussion_r41133343
  
    --- Diff: tools/docker/Dockerfile.centos6 ---
    @@ -23,15 +23,19 @@ LABEL Vendor="Apache.org" License="ApacheV2" Version="4.6.0"
     ENV PKG_URL=http://jenkins.buildacloud.org/job/package-rhel63-master/lastSuccessfulBuild/artifact/dist/rpmbuild/RPMS/x86_64
     
     # install CloudStack
    -RUN yum install -y \
    +RUN yum install -y nc wget \
         ${PKG_URL}/cloudstack-common-4.6.0-SNAPSHOT.el6.x86_64.rpm \
         ${PKG_URL}/cloudstack-management-4.6.0-SNAPSHOT.el6.x86_64.rpm
     
     RUN cd /etc/cloudstack/management; \
         ln -s tomcat6-nonssl.conf tomcat6.conf; \
         ln -s server-nonssl.xml server.xml; \
    -    ln -s log4j-cloud.xml log4j.xml
    +    ln -s log4j-cloud.xml log4j.xml; \
    +    cd /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver; \
    +    wget http://download.cloud.com.s3.amazonaws.com/tools/vhd-util
    --- End diff --
    
    vhd-utils is added because it's really not fun adding it once deployed. it also does not break support for KVM.
    
    As this dockerfile is not using noredis build, should we have a seperate image including all the noredis which would also include vhd-utils?   if so, the basic build would only work with KVM then :-S



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: Dockerfile part2

Posted by pdion891 <gi...@git.apache.org>.
Github user pdion891 commented on the pull request:

    https://github.com/apache/cloudstack/pull/910#issuecomment-152054216
  
    remote branch broken. closing this PR...


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---