Commit Graph

327 Commits (087cea8c2e15f7b72ebfc2d380bdcdedcccc74a4)

Author SHA1 Message Date
Alexander Garagatyi a1c9efd6a8 CHE-4310: improve UX of usage of official docker images for machines
Add tail -f /dev/null into containers that exits on start.
Check if container is running after start of container.
Signed-off-by: Alexander Garagatyi
2017-04-26 15:25:55 +03:00
Roman Iuvshin 6d88cf8c73 [maven-release-plugin] prepare for next development iteration 2017-04-25 18:19:17 +00:00
Roman Iuvshin d7f023fd89 [maven-release-plugin] prepare release 5.9.0 2017-04-25 18:19:10 +00:00
Roman Iuvshin 7805c146e6 [maven-release-plugin] prepare for next development iteration 2017-04-13 11:07:13 +00:00
Roman Iuvshin e8107fd96c [maven-release-plugin] prepare release 5.8.0 2017-04-13 11:07:06 +00:00
Vitalii Parfonov e9d4c45b81 Json rpc critical fix (#4798)
* initial commit

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* fixed build

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* Remove not needed subscription

Signed-off-by: Vitalii Parfonov <vparfonov@codenvy.com>
2017-04-12 20:19:48 +03:00
Roman Iuvshin 840ae853f8 Revert "RELEASE: set minor change version"
This reverts commit e23b9257a3.
2017-04-11 20:55:24 +03:00
Roman Iuvshin e23b9257a3 RELEASE: set minor change version 2017-04-11 18:10:45 +03:00
Mykola Morhun 46781cbf29 CHE-4497: Delete snapshots from docker hub (#4744) 2017-04-11 11:11:40 +03:00
Dmitry Kuleshov 5d16a15078 Setting up a websocket JSONRPC API endpoint on master (#4621)
* added jsonrpc connection between IDE and MASTER

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* replaced message bus with json rpc

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* applied remarks

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* added jsonrpc connection between IDE and MASTER

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* replaced message bus with json rpc

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* applied remarks

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* fixed javadoc

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* added websocket config

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>

* fixed failing build

Signed-off-by: Dmitry Kuleshov <dkuleshov@codenvy.com>
2017-04-07 14:44:43 +03:00
Roman Iuvshin 08d4d0f25c [maven-release-plugin] prepare for next development iteration 2017-04-06 14:28:39 +00:00
Roman Iuvshin 53a0325213 [maven-release-plugin] prepare release 5.7.0 2017-04-06 14:28:33 +00:00
Florent BENOIT 45da3d93bc Sets CHE_WORKSPACE_ID and CHE_MACHINE_NAME in all machines started by Che (#4649)
* Set CHE_WORKSPACE_ID and CHE_MACHINE_NAME in all machines started through CHE
it is required for single port /reverse proxy strategy

Change-Id: Ib2cb987e594929151de4c26b614b91d788d19869
Signed-off-by: Florent BENOIT <fbenoit@codenvy.com>
2017-04-03 10:20:28 +02:00
Mykola Morhun df1b603ed3 CODENVY-1936: Add alias index.docker.io for docker hub (#4572)
CODENVY-1936: Add alias index.docker.io for docker hub
2017-03-31 15:14:53 +03:00
Alexander Garagatyi b9ebdc2cb4 CODENVY-1734: improve docker client (#4620)
Throw specific exception in docker client
if exec not found on exec start.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-03-30 18:08:42 +03:00
Roman Iuvshin 342f103654 [maven-release-plugin] prepare for next development iteration 2017-03-30 12:25:35 +00:00
Roman Iuvshin e6e4a652cc [maven-release-plugin] prepare release 5.6.0 2017-03-30 12:25:28 +00:00
Alexander Garagatyi 798ca081b4 CHE-4098: separate terminal and exec agents (#4486)
Refactor golang terminal code.
Add ping frames into terminal websocket connection.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-03-27 12:27:27 +03:00
Roman Iuvshin e7588aa2b3 [maven-release-plugin] prepare for next development iteration 2017-03-15 14:59:35 +00:00
Roman Iuvshin 69cf9f5528 [maven-release-plugin] prepare release 5.5.0 2017-03-15 14:59:28 +00:00
Vitalii Parfonov 0951e40d69 CHE-3620:Remove MachineServiceClient and related classes (#3963) 2017-03-07 14:36:31 +00:00
Max Shaposhnik 11ec789ca5 CHE-3616 Remove Machine API (server part) (#4331) 2017-03-07 14:33:05 +00:00
Roman Iuvshin ceff3938ff [maven-release-plugin] prepare for next development iteration 2017-03-02 18:33:12 +00:00
Roman Iuvshin 8ed6e10476 [maven-release-plugin] prepare release 5.4.0 2017-03-02 18:33:06 +00:00
Angel Misevski 1d9c426e2d Ensure OpenShift pod is terminated before returning from removeContainer (#4230)
Prevents issue where it is possible to start workspace while
pod is terminating. When this occurs, Che creates a new pod but
workspace start fails. This pod must be removed manually before
that workspace can be launched again.

This is done by a) waiting for pod to terminate before returning
from removeContainer, and b) removing created deployment and
service when an exception occurs during createContainer.

Additionally, increases maximum wait time for retreiving
OpenShift image stream metadata

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-03-01 00:56:32 -05:00
Mario Loriedo c8145259e5 Implement getEvents method in OpenShiftConnector
Signed-off-by: Mario Loriedo <mloriedo@redhat.com>
2017-02-28 17:38:11 +01:00
Angel Misevski 54e60a52b4 Add OpenShift implementation of getNetworks()
Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-02-24 15:58:44 +01:00
rawlingsj 2fc5373524 kubernetes-client will autodetect auth details both inside and outside openshift so no need to use config
for more information including the order configuration is decided see https://github.com/fabric8io/kubernetes-client#configuring-the-client

fixes https://issues.jboss.org/browse/CHE-117

Signed-off-by: rawlingsj <rawlingsj80@gmail.com>
2017-02-22 22:38:23 +01:00
Roman Iuvshin e71c7b5671 [maven-release-plugin] prepare for next development iteration 2017-02-17 11:04:07 +00:00
Roman Iuvshin c071c65aa2 [maven-release-plugin] prepare release 5.3.0 2017-02-17 11:03:59 +00:00
Alexander Garagatyi e55dd12e70 CODENVY-1403: fix bug in machine removal (#4154)
Bug occurs when container is unavailable without stop of machine.
In that case we don't stop machine instance and not cleanup
resources.
Signed-off-by: Alexander Garagatyi
2017-02-16 17:05:24 +02:00
Igor Vinokur 227261a2c7 CHE-3973: Fix deletion of WS folder on WS deletion (#4122) 2017-02-15 16:43:48 +02:00
Alexander Garagatyi 6032c5905d CODENVY-1749: add possibility to set dns resolvers (#4129)
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-02-15 12:47:46 +02:00
Yevhenii Voevodin 9370327d46 Inject MAVEN_OPTS environment variable along with JAVA_OPTS to container 2017-02-14 17:50:56 +02:00
Angel Misevski ad318b0fa1 Refactor inspectContainer() and add commit(), removeImage() (#4085)
Adds commit() and removeImage() implementations to
OpenShiftConnector. This requires some refactoring of existing
methods (mostly refactoring repeated processes into their own
methods -- e.g. creating an ImageStreamTag and getting image
info from a tag).

Additionally, refactors inspectContainer() method to remove
a call to DockerConnector, instead obtaining the same information
from what's available through the OpenShift API. This fixes an
issue where the IP address of a workspace was unavailable from
the ContainerInfo returned by DockerConnector.

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-02-11 01:10:29 +01:00
Mario Loriedo bbb2bc9bf2 OpenShiftConnector OAuth token support (#4049)
Signed-off-by: Mario Loriedo <mloriedo@redhat.com>
2017-02-10 10:50:59 +01:00
Sergii Kabashniuk ccad9082cc che-plugin-docker-client remove all gwt code since its only a ws-master dependency (#4079) 2017-02-09 22:18:10 +02:00
Angel Misevski b6a056fa22 Implement OpenShift pull, tag, and inspectImage
Implement OpenShiftConnector pull, tag, and inspectImage through
ImageStreams. Makes changes to how containers are created.

Currently snapshots do not work, as commit and push methods are not
implemented. Additionally, pulling a stack from a private repository
is not supported.

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-02-09 01:26:57 +01:00
Snjeza 65c38ed507 Fixing failed tests (#4065)
Signed-off-by: Snjezana Peco <snjezana.peco@redhat.com>
2017-02-08 21:33:45 +02:00
Snjezana Peco 41541e0b99 CHE-3953 - Starting workspace on openshift 1.4.1
Signed-off-by: Snjezana Peco <snjezana.peco@redhat.com>
2017-02-08 17:03:17 +01:00
Alexander Garagatyi bee9890e4e CODENVY-1443: fix incorrect usage of non bind-mount volumes (#3877)
Add other minor fixes
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-02-06 10:44:30 +02:00
Roman Iuvshin 0dd0dea686 [maven-release-plugin] prepare for next development iteration 2017-02-01 13:31:32 +00:00
Roman Iuvshin d138c3623f [maven-release-plugin] prepare release 5.2.0 2017-02-01 13:31:25 +00:00
Ilya Buziuk e102dd0f6f CHE-42: Adding stub implementation of Container API for OpenShiftConnector. Minor Refactoring
Signed-off-by: Ilya Buziuk <ibuziuk@redhat.com>
2017-01-31 12:57:40 +01:00
Ilya Buziuk 25fc88be80 CHE-3937: Introducing properties for OpenShift liveness probe initial delay / timeout
Signed-off-by: Ilya Buziuk <ibuziuk@redhat.com>
2017-01-31 01:52:31 +01:00
Ilya Buziuk 1ec641a7e8 CHE-58: Refactoring. Introducing new classes for handling Kubernetes resources (KubernetesContainer, KubernetesService, KubernetesEnvVar)
Signed-off-by: Ilya Buziuk <ibuziuk@redhat.com>
2017-01-27 17:33:45 +01:00
Angel Misevski 6e9964c2a2 Add DockerConnectorProvider to allow choosing OpenShiftConnector
Adds class so that choice between DockerConnector and OpenShiftConnector
can be made via setting a property in che.properties. The provider is
injected instead of DockerConnector, and provides the appropriate
implementation through a get() method.

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-01-27 17:33:45 +01:00
Mario Loriedo 364e06f1e5 Added an OpenShift connector for container creation
Signed-off-by: Mario Loriedo <mloriedo@redhat.com>
2017-01-27 17:33:45 +01:00
Mykola Morhun 491e84c4f4 Merge pull request #3854 from eclipse/CHE-3761
CHE-3761: Workaround illegal response from docker
2017-01-25 17:35:53 +02:00
Mykola Morhun 956d39183d CODENVY-1393: Limit CPU consumption by build docker image tasks
Signed-off-by: Mykola Morhun <mmorhun@codenvy.com>
2017-01-25 12:19:20 +02:00
Mykola Morhun 52f1e471ae CHE-3761: Workaround illegal response from docker
Signed-off-by: Mykola Morhun <mmorhun@codenvy.com>
2017-01-23 14:23:56 +02:00
Alexander Garagatyi 6b46f73c2c CHE-3686: fix docker machines addresses setting
Set internal machine address by CLI from CHE_IP.
Add and fix docs in che.env.
Change behavior of default machine server address evaluation
to be similar to the previous state.
Code cleanup.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-01-20 18:10:32 +02:00
Roman Iuvshin 05a7cd53b5 [maven-release-plugin] prepare for next development iteration 2017-01-18 16:33:24 +00:00
Roman Iuvshin 41d3739928 [maven-release-plugin] prepare release 5.1.0 2017-01-18 16:33:17 +00:00
Mykola Morhun d9dd16a7e0 CODENVY-1524: Inject API endpoint env variable into all machines
Signed-off-by: Mykola Morhun <mmorhun@codenvy.com>
2017-01-18 15:07:56 +02:00
Yevhenii Voevodin 1ede4845c4 Implement cancellation (#3701) 2017-01-16 18:05:45 +02:00
Alexander Garagatyi 5b94510beb CODENVY-1150: Refactor docker hosts evaluation
Make addition of che host into hosts file optional.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-01-12 09:41:03 +02:00
Alexander Garagatyi f4ade80ec1 Refactor workspace infrastructure provisioning
Move agents volume addition into infrastructure provisioner.
Suppress some false positive warnings.
Add some javadocs.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2017-01-11 15:56:08 +02:00
Yevhenii Voevodin a704338c6e Use getConfig() instead of null while creating machine metadata (#3662) 2017-01-11 12:13:39 +02:00
Yevhenii Voevodin 8674d2228f Load instance runtime information on machine start (#3561) 2017-01-10 23:48:49 +02:00
Alexander Garagatyi 33a4d073fb Merge pull request #3282 from amisevsk/CHE-2030-refactor
Refactor DockerInstanceRuntimeInfo#getServers() (#2030)
2017-01-10 10:12:42 +02:00
Roman Iuvshin 9904460818 [maven-release-plugin] prepare for next development iteration 2017-01-06 11:48:49 +00:00
Roman Iuvshin b5a7d04ca2 [maven-release-plugin] prepare release 5.0.0 2017-01-06 11:48:42 +00:00
Angel Misevski 3473c01472 CHE-2030: Exclude files related to PR #3282 from license check
The current license checking maven plugin does not allow
for multiple copyright owners on source files. This commit
adds files modified for ServerEvaluationStrategy to an excludes
list so that builds can continue normally.

This commit should be undone once issue #3281 is resolved.

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-01-05 13:52:42 -05:00
Angel Misevski 6b5c10ce74 CHE-2030: Replace getServers() implementation
Replaces DockerInstanceRuntimeInfo#getServers() to use
ServerEvaluationStrategy. Deletes LocalDockerInstanceRuntimeInfo
class as it is no longer needed. Adds MapBinder of
ServerEvaluationStrategy to LocalDockerModule.

Updates DockerInstanceRuntimeInfo tests to be more
readable and removes now unnecessary tests.

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-01-05 13:52:42 -05:00
Angel Misevski f7d247a0d9 CHE-2030: Add tests for ServerEvaluationStrategy
Add tests for ServerEvaluationStrategy, DefaultServerEvaluationStrategy,
and LocalDockerServerEvaluationStrategy

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-01-05 13:52:42 -05:00
Angel Misevski d00ff2962b CHE-2030: Add ServerEvaluationStrategies and Provider
Adds abstract class ServerEvaluationStrategy which can be used to
change how Che Server communicates with workspace containers.
ServerEvaluationStrategy is meant to be extended to modify the behavior
of DockerInstanceRuntimeInfo#getServers().

Two implementations of ServerEvaluationStrategy are included:
DefaultServerEvaluationStrategy (which is identical to normal
getServers() functionality) and LocalDockerServerEvaluationStrategy,
which uses internal container addresses for workspace containers
and can help in cases where firewall is an issue.

Strategies are provided by ServerEvaluationStrategyProvider, which
uses the new property che.docker.server_evaluation_strategy to choose
which implementation is provided.

Signed-off-by: Angel Misevski <amisevsk@redhat.com>
2017-01-05 13:52:42 -05:00
Mihail Kuznyetsov 0e8b21ad3f Set new license year 2017-01-04 17:10:31 +02:00
Mykola Morhun c53693d5fa CHE-3549 Fix docker privileged mode (#3562)
CHE-3549: Fix privileged mode
2016-12-29 10:01:04 +02:00
Mykola Morhun 2c855c68ac Che 3135: Clean up abandoned docker networks created by CHE (#3348)
CHE-3135: Clean up abandoned docker networks created by CHE
2016-12-23 16:23:56 +02:00
Roman Iuvshin abc1367c1d remove milestone from version 2016-12-23 15:04:56 +02:00
Roman Iuvshin 813d930275 change version to M10-SNAPSHOT 2016-12-22 11:48:31 +02:00
Alexander Garagatyi 1eceaebe75 CODENVY-1271: fix agent launching in some cases
Fix AbstractAgentLauncher.
Code cleanup.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2016-12-21 16:28:37 +02:00
Kaloyan Raev 5bb51e0344 Fix for using the official mysql image in composite stacks (#3049)
* Avoid passing empty array for command and entrypoint to Docker API
* Use official mysql docker image in the java-mysql stack

Signed-off-by: Kaloyan Raev <kaloyan.r@zend.com>
2016-12-20 16:17:37 +02:00
Snjeza 9f5a7fb027 CHE-3129 - Project can't be created without Z option (#3130)
Signed-off-by: Snjezana Peco <snjezana.peco@redhat.com>
2016-12-15 15:06:41 +02:00
Florent BENOIT 5266cd930e machine.getOwner() should return userId and not a namespace (#3366)
Fix #3042

Change-Id: I64b4cd3931fec502073ead0115a312430f2434b8
Signed-off-by: Florent BENOIT <fbenoit@codenvy.com>
2016-12-14 02:01:28 -07:00
Alexander Garagatyi 42272e4bd9 CHE-3199: add cpu limits configuration (#3278)
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2016-12-07 17:39:59 +02:00
Roman Iuvshin 7850cc2908 [maven-release-plugin] prepare for next development iteration 2016-12-07 12:34:30 +00:00
Roman Iuvshin 1c15a44844 [maven-release-plugin] prepare release 5.0.0-M8 2016-12-07 12:34:25 +00:00
Max Shaposhnik afadcd24f3 CHE-3065 Add uncaught exceptions handler in threads being run by ExecutorService (#3174) 2016-11-28 11:50:50 +02:00
Igor Vinokur c91257f46b CODENVY-657: Do not log SourceNotFoundException (#3084) 2016-11-22 22:55:25 +02:00
Max Shaposhnik 44b6e46361 CODENVY-1127; Avoid of concurrent snapshots on same node. (#3125) 2016-11-18 16:53:54 +02:00
Alexander Garagatyi 9a60f0744f CHE-3114: Fix projects mount permissions
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2016-11-18 09:38:59 +02:00
Aleksandr Andrienko 6100119a68 CHE-2365: Add deserializer for 'command' field ComposeServiceImpl. (#2807)
Move compose parser to separate module.

Signed-off-by: Aleksandr Andrienko <aandrienko@codenvy.com>
2016-11-17 19:18:36 +02:00
Snjezana Peco b7682ddde7 CHE-2874 Let users configure the 'Z' flag when mouting a volume
Signed-off-by: Snjezana Peco <snjezana.peco@redhat.com>
2016-11-17 14:51:40 +01:00
Anatoliy Bazko b0c4235f1e INFRA-14: Limits number of pids (#3075)
* INFRA-14: Limits number of pids
2016-11-15 12:34:58 +02:00
Alexander Garagatyi 0c81935f21 [WIP] Hackathon merge (#3013)
Refactors workspace bootstrapping code:
Addition of projects volumes to ws-machines and 
applying of agents moved to infrastructure provisioner. 
It can be overwritten in any implementation of Che and 
will be responsible for providing all infrastructure needed for Che implementation functioning.
Allow to configure environment network driver.
Allow to add Agents from the code instead of special files. 
These agents can override agents configured in files if identifiers are equal.
Adds possibility to host agents binaries from CHE master.
Reworks agents in a way when they can be downloaded from CHE master if they are not found on FS.
Adds workspace ID to internal representation of environment to allow to use it for internal purposes of machine bootstrapping.
Renames some properties.
Refactors AgentConfigApplier to encapsulate additional code that was used with this class before.
Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
2016-11-11 18:21:28 +02:00
Roman Iuvshin 52f84d9092 [maven-release-plugin] prepare for next development iteration 2016-11-10 11:37:24 +00:00
Roman Iuvshin 315056731e [maven-release-plugin] prepare release 5.0.0-M7 2016-11-10 11:37:20 +00:00
Aleksandr Andrienko 2a0081e174 CHE-2927: Add logs for active containers checked by DockerContainerCleaner. (#2950)
Signed-off-by: Aleksandr Andrienko <aandrienko@codenvy.com>
2016-11-01 17:53:08 +02:00
Mykola Morhun d74b24fb07 Fix broken links section in docker-compose recipe (#2850) 2016-10-31 16:22:48 +02:00
Anatoliy Bazko eb03a17917 CHE-2832: Add servers to Agent description and propagate them to Workspace Runtime (#2868) 2016-10-31 09:17:15 +02:00
Mihail Kuznyetsov 494442e11a CHE-2015 Rename configuration properties 2016-10-27 17:29:46 +03:00
Roman Iuvshin 825af31a5d [maven-release-plugin] prepare for next development iteration 2016-10-26 09:37:49 +00:00
Roman Iuvshin 7da1d4a910 [maven-release-plugin] prepare release 5.0.0-M6 2016-10-26 09:37:45 +00:00
Aleksandr Andrienko f2661c97f4 Fix test which periodically failed. (#2835)
Signed-off-by: Aleksandr Andrienko <aandrienko@codenvy.com>
2016-10-20 11:32:49 +03:00
Mario Loriedo a33fdf142b Add build args support in compose files (CHE-2661)
Signed-off-by: Mario Loriedo <mloriedo@redhat.com>
2016-10-18 22:14:55 -06:00
Aleksandr Andrienko 291dbb89ba CHE-2435: Clean up workspace files after remove workspace. (#2544)
Signed-off-by: Aleksandr Andrienko <aandrienko@codenvy.com>
2016-10-18 23:05:24 +03:00
Florent BENOIT f2c8529792 Use of /bin/sh for script invocation
Allow to override /bin/sh by a "shell" attribute in commands

Change-Id: I19b95868c44f473552a153e29d1ba41abcc19aef
Signed-off-by: Florent BENOIT <fbenoit@codenvy.com>
2016-10-11 15:00:46 +02:00
Roman Iuvshin b986091e4a [maven-release-plugin] prepare for next development iteration 2016-10-07 10:22:41 +00:00