Is it possible to start and build Rocket.Chat without ee directory(without enterprise code)? - rocket.chat

I'm playing with rocket.chat and trying to build my own custom CE build.
Now when I'm trying to start it locally meteor npm start it works fine, without any errors.
But after deleting '/ee' directory and meteor npm start:
Error: Cannot find module '../ee/server/broker'
...
=> Exited with code: 1
=> Your application is crashing. Waiting for file change.
From the release notes
Also, it is worth mentioning that you are able to delete the entire EE repository if you wish to.
So the question is can I exclude enterpise code and run rocket.chat locally for development and later on make a custom build of Rocket.Chat CE.
Rocket.Chat#3.8.0-develop.
I haven't added new code yet.
Thanks in advance

Related

Gitlab CI - Auto DevOps job failed, Unable to select a buildpack for a Go project?

My Gitlab CI Auto DevOps job failed with
Status: Downloaded newer image for gliderlabs/herokuish:latest
-----> Unable to select a buildpack
ERROR: Job failed: exit code 1
I've gone through
Auto DevOps and
Getting started with Auto DevOps
and am still not sure where I should put the buildpack.
Mine should be heroku-buildpack-go, which I've lost track where I get that from.
My repo consist only a single-character README.md, and the "Hello, playground" main.go.
Conclusion:
Thanks to David's comprehensive explanation, I was able to get DevOps started with correct buildpack:
From this I would conclude that your single .go file at the root of the directory tree does not meet the activation criteria for auto-building Go projects. I'd suggest picking one of the dependency managers in the requirements above and modifying your project to support it.
FTA, I just did touch go.mod then git add & git push and the AutoDevops started building my GO project indeed.
However it seems to me that Gitlab AutoDevops is not able to build any GO projects very easily, as I get the following error (with project variable TRACE=true):
...
!! The go.mod file for this project does not specify a Go version
!!
!! Defaulting to go1.11.1
!!
!! For more details see: https://devcenter.heroku.com/articles/go-apps-with-modules#build-configuration
!!
-----> Installing go1.11.1
-----> Fetching go1.11.1.linux-amd64.tar.gz... done
!! Installing package '.' (default)
!!
!! To install a different package spec add a comment in the following form to your `go.mod` file:
!! // +heroku install ./cmd/...
!!
!! For more details see: https://devcenter.heroku.com/articles/go-apps-with-modules#build-configuration
!!
-----> Running: go install -v -tags heroku .
go: cannot determine module path for source directory /tmp/build (outside GOPATH, no import comments)
ERROR: Job failed: exit code 1
The easier solution is to use .gitlab-ci.yml file instead, documented in
https://blog.boatswain.io/post/build-go-project-with-gitlab-ci/
(and followed up at Gitlab CI - Start Shared Runner for normal repos).
From the AutoDevops documentation:
Auto Build creates a build of the application in one of two ways:
If there is a Dockerfile, it will use docker build to create a Docker image.
Otherwise, it will use Herokuish and Heroku buildpacks to automatically detect and build the application into a Docker image.
Then looking at the build activation criteria, as per the Heroku Go buildpack documentation:
This buildpack will detect your repository as Go if you are using either:
go modules
dep
govendor
glide
GB
Godep
Or more specifically for godep, govendor or GB:
The Heroku Go buildpack is used when an application meets one of the following requirements:
has a Godeps/Godeps.json file, identifying the application as being managed by godep;
has a vendor/vendor.json file, identifying the application as being managed by govendor;
has a src directory, which has sub directories, contains one or more .go files, identifying the application as being managed by gb.
From this I would conclude that your single .go file at the root of the directory tree does not meet the activation criteria for auto-building Go projects. I'd suggest picking one of the dependency managers in the requirements above and modifying your project to support it. After that AutoDevops should start building your project.
If you are still having issues after that, this debugging note might help:
After making sure that the project meets the buildpack requirements;
if it still fails, setting a project variable TRACE=true will enable verbose logging which​ may help to continue troubleshooting.

Xamarin.UITest AppCenter Cannot find test-cloud.exe

I have created Xamarin.UITest that can run locally on my desktop. My goal is to execute these test as a part of a post-build script to run UITest after the app has built as mentioned in this article below:
https://tomsoderling.github.io/AppCenter-Automated-UI-tests-on-build/
Below is my script
appcenter test run uitest --app "MY-APP" --devices 168683d9 --app-path $APPCENTER_OUTPUT_DIRECTORY/MyApp.Mobile.Droid.apk --test-series "myapp-mobile-test" --locale "en_US" --build-dir $APPCENTER_SOURCE_DIRECTORY/MyApp.Mobile.UITests/bin/Release --token MY-TOKEN --uitest-tools-dir $APPCENTER_SOURCE_DIRECTORY/packages/Xamarin.UITest.*/tools
When the script above is apart of my appcenter post build script, I get the following error:
Error: Cannot find test-cloud.exe, the path specified by "--uitest-tools-dir" was not found.
Please check that "/Users/vsts/agent/2.141.1/work/1/s/packages/Xamarin.UITest.2.2.6/tools" is a valid directory and contains test-cloud.exe.
Minimum required version is "2.2.0".
I think a lot of people are having trouble dealing with this actually and I know it has something to do with --uitest-tools-dir OR --build-dir variables.
Keep in mind this I am first trying to do this with Xamarin.Android, if successful I will try the Xamarin.iOS
One clue i do see is when Tom says "I had to chose to build the app solution file in my App Center CI build - not simply the iOS project like I normally would" in the noted article, but I am not quite sure how to do that or if is connected to why AppCenter cannot locate my test-cloud.exe I will also say that test-cloud.exe somehow comes from the Xamarin.UITest nuget, but I do not see any test-cloud.exe file in my Xamarin.Forms project.
This answer works, but it's pretty fragile.
The test-cloud.exe can't be located at packages/Xamarin.UITest.2.X.X/tools in projects that uses the old project structure (projects that use packages.config). For new projects (new .csproj formats), there is no such file in the path of the project. The only way I found to make it work on AppCenter is to use it from the NuGet package cache (/Users/vsts/.nuget/packages/xamarin.uitest/2.X.X)
Kudos to AppCenter Agents for helping me to resolve this. 2 things were required as indicated below:
Agent Anvesh says
Hi there, Thanks for the details, So seems like you are using a nuget as a PackageReference in your project(this means that there will be no package folder in your project, packages will be there at user profile).
So when you are trying to run the test as part of the app center build. Then in the shell script used the --uitest-tools-dir value as below
/Users/vsts/.nuget/packages/xamarin.uitest/2.2.6/lib/tools
So I modified my above script to add the below:
--uitest-tools-dir /Users/vsts/.nuget/packages/xamarin.uitest/2.2.6/tools \
Agent Shawn says
So I added the below
msbuild $APPCENTER_SOURCE_DIRECTORY/MyApp.Mobile.UITestProject.csproj

Android Studio Gradle Build Error: Read Time Out

I have the latest Android Studio IDE installed on my Windows 10 laptop, and it was working fine until my windows operating system made a huge automatic update.
Now, when start my Android Studio IDE, I get the following error and it doesn't build.
Gradle sync failed: Read timed out Consult IDE log for more details
(Help | Show Log) (3m 34s 195ms)
I need help on this.
I encounter this error "Read Time Out", and I simply choose menu item: File -> Invalidate Caches / Restart... to fixed it.
[UPDATE]
I just encounter this error for second time, this time Invalidate Caches / Restart... not able to fix it, but then I try close the android Studio, killall -9 java to ensure all java process has been terminated, then relaunch Android Studio, no more error.
[UPDATE 2]
I just encounter this error and I fixed it by replug the phone cable and rerun.
I got around this issue by turning on Offline Mode in the Gradle tool window.
I have just synced the Project with Gradle files and it worked
Editing global gradle.properties with the following line was the fix for me:
org.gradle.jvmargs=-Dorg.gradle.internal.http.connectionTimeout=120000 -Dorg.gradle.internal.http.socketTimeout=120000
For Chinese users who often use a proxy to download dependency jars, the cause is often proxy settings.
We should check multiple places if the proxy is correctly configured.
Android Studio Settings - Appearance & Behavior - System Settings - HTTP Proxy
${project_root}/gradle.properties
~/.gradle/gradle.properties
In my case, I somehow once configured an HTTP proxy in ~/.gradle/gradle.properties, which was forgotten later. Then when I dealt with a SOCKS5 proxy in IDE Settings and project-level gradle.properties, things always run into trouble. Finally, deleting invalid proxy settings in ~/.gradle/gradle.properties save my day.
I fixed the error by inserting following lines in gradle.properties:
systemProp.org.gradle.internal.http.connectionTimeout=180000
systemProp.org.gradle.internal.http.socketTimeout=180000
This sets the Gradle's connection timeout from the default 30s to 180s (3m).
In my case the read timeout occurred because my computer is behind a HTTP proxy, and it failed to timely connect to http://jcenter.bintray.com.
For more info about the Gradle options, you can refer to https://github.com/gradle/gradle/issues/3370
Simple Answer:
Check the Internet Connection - it should not fluctuate while building the project
File-->>Sync Project with Gradle File
Build>> Clean Project Or Rebuild Project.
I just removed
include ':app'
from setting.gradle and then sync project
it will fails again
then write it back an re-sync and then error gone and will start downloading.
Here's what worked for me (on Windows):
From C:\Users\{$user}\.gradle
Delete these 3 folders:
caches
daemon
wrapper
Then restart Android Studio and Gradle should start downloading automatically
None of the answer worked for me.
I solved it by
Delete project>.gradle directory
File>Sync Project with Gradle Files
In my case it was due to Jitpack.io server down, causing my project unable to build. So I just enabled the Offline Mode for gradle to continue developing my project while Jitpack.io is resolving their server issue.
You will see more info when you click "build" on top of the "read time out" message in build output. In my case, it was a facebook dependency issue so I just had to upgrade it to a newer version.
In my case, it was a firewall issue. After adding Android Studio to its whitelist everything is working fine.
A simple Clean Project + Rebuild Project worked for me
I resumed working on my project after a long time and I was using an Old version of navigation dependency.
after updating version to versions.navigation = "2.3.0" from versions.navigation = "2.3.0-aplha01" my issue was resolved.
so in short make sure you are using latest version of gradle and all libraries (compatible with your gradle version).
Above fixes didn't work for me on MacOS Big Sur 11.5.1 after updating to the new version of Arctic Fox 2020.3.1 Patch 3.
My issue with this was resolved by doing the following:
Close your Android project
Navigate to the root folder of you project
Remove the '.gradle' and '.idea' folders
Start your Android project, which will start the build process. Let this finish
Now the build should succeed. If not, also do an 'Invalidate caches/restart'
In my case, this error was showing up while I am trying to create a new project,
and the default Kotlin Gradle plugin API version was the culprit,
While building/Gradle sync I noticed that the sync process is always getting stuck at the downloading kotlin.gradle.plugin.api:1.5.21,
So I searched for 1.5.21 in the build.gradle and updated it to the latest version, and it worked.
Just Simple Step and you Got Solution.
Android Studio -> FILE -> Invalid Caches / Restart -> Invalidate and Restart
Done Keep Code ☻♥
In my case, Android Studio Arctic Fox | 2020.3.1 Patch 4 (Windows)
I have try 3 step/solution;
Delete 2 root folder .gradle & .idea but still give 'Read timeout'
Invalid Caches/Restart also resulted 'Read timeout'
Close Android Studio, repeat solution 1, monitor 'Build Output' log, then choose 'Disable gradle offline..." , wait and let Android Studio do its thing, then on the log Build showed "BUILD SUCCESSFUL in 28s". Then, I try to run the app just to check and my apps still work as usual.
*Remark: This case happened might be because of my Android Studio IDE Version outdated. As for now, latest version is Android Studio Dolphin | 2021.3.1 Patch 1 .
This error got due to the internet connection during gradles files connection interrupts.
I tried the following techniques but unfortunately, didn't get any solution.
File->Invalidate Cache.
File->Sync Project with .gradle files
Delete Project .gradle and .idea files.
I got the solution to update gradle-wrapper.properties 6.8 to 7.1 after successfully sync revert back from 7.1 to 6.8
#distributionUrl=https://services.gradle.org/distributions/gradle-7.1-bin.zip
distributionUrl=https://services.gradle.org/distributions/gradle-6.8-bin.zip
Use the following code in gradle.properties :
systemProp.http.proxyHost=www.somehost.org
systemProp.http.proxyPort=8080
systemProp.http.proxyUser=userid
systemProp.http.proxyPassword=password
systemProp.http.nonProxyHosts=*.nonproxyrepos.com|localhost
org.gradle.daemon=false

Bamboo build error: How to properly clean bamboo caches?

The problem:
Bamboo executes old unit tests that don't exist my current develop branch which causes a build error.
The situation that causes this problem:
After a big refactoring process of my maven java project, where I basically moved, modified and renamed every file, I committed my changes to my remote repository.
That triggered my bamboo build plan, to start the build process.
The git code checkout seems to work, but the next step, running the unit tests, fails!
Looking in the log file I see that an old, no more existing java Unit test class gets executed and of course fails because of NullPointerExceptions.
Things I tried to fix this problem
A. Remove caches in the Administration section
I went to Bamboo->Administration->Repository Settings and selected
the cache of my project and deleted it.
I started the build plan again
BUILD ERROR ! Same problem
B. Delete the cache directory in the file system
Start a RDP session on the bamboo server
stop bamboo
go to D:\bamboo-home_64\xml-data\build-dir_git-repositories-cache
delete all files in this folder
start bamboo
start the build plan again
BUILD ERROR! same problem
Meta info
bamboo version: 6.1.0 build 60103 - 18 Jul 17
I don't know what I can do to fix this..
There's Clean working directory task. Add it as first task to your Job and see if it solves the issue.

Mule Plugin for Maven

I'm using the mule-maven-plugin as explained here: https://docs.mulesoft.com/mule-user-guide/v/3.7/mule-maven-plugin#running-integration-tests , using "mvn deploy" will donwload the mule 3.7.2 to the target folder but standalone won't fire up, instead it throws this error
The Mule Enterprise Edition service was launched, but failed to start.
If i manually trigger the mule.bat everything works as expected and standalone is able to run the projects on the app/ folder.
Logs: https://drive.google.com/folderview?id=0B-RSwLHJZLJqckJESVJpMEJqeUU&usp=sharing
Carlos, I see a couple of thigs in the logs:
Unable to install the Mule Enterprise Edition service - El servicio especificado ya existe. (0x431)
Probably you already have a Mule service running, can you try stopping it before running the plugin?
[INFO] Using MULE_HOME: C:\cygwin64\home\Carlos Parra\workspace\mule\dummy-project\target\mule-enterprise-standalone-3.7.2
If (1) doesn't solve the problem can you try to use a directory without spaces?
Please tell me if this works.

Resources