From bf78a80f2908df6254409013a301ccf3ec2e653d Mon Sep 17 00:00:00 2001 From: fabianofranz Date: Wed, 1 Oct 2014 14:42:17 -0300 Subject: [PATCH] Fixes OpenShift build --- .openshift/action_hooks/build | 13 +- .openshift/cron/README.cron | 27 ---- diy/index.html | 279 ---------------------------------- diy/testrubyserver.rb | 14 -- misc/.gitkeep | 0 pom.xml | 2 +- 6 files changed, 13 insertions(+), 322 deletions(-) delete mode 100644 .openshift/cron/README.cron delete mode 100644 diy/index.html delete mode 100755 diy/testrubyserver.rb delete mode 100644 misc/.gitkeep diff --git a/.openshift/action_hooks/build b/.openshift/action_hooks/build index 01fb76b8..5d848806 100755 --- a/.openshift/action_hooks/build +++ b/.openshift/action_hooks/build @@ -1,11 +1,22 @@ #!/bin/bash cd $OPENSHIFT_REPO_DIR +rm -rf $OPENSHIFT_REPO_DIR/node +rm -rf $OPENSHIFT_REPO_DIR/node_modules +rm -rf $OPENSHIFT_TMP_DIR/npm +rm -rf $OPENSHIFT_TMP_DIR/npmrc +rm -rf $OPENSHIFT_TMP_DIR/m2 +rm -rf $OPENSHIFT_TMP_DIR/local + +export NPM_CONFIG_PREFIX="$OPENSHIFT_TMP_DIR/npm" +export NPM_CONFIG_USERCONFIG="$OPENSHIFT_TMP_DIR/npmrc" export NPM_CONFIG_CACHE="$OPENSHIFT_TMP_DIR/npm/cache" export MAVEN_OPTS="-Dmaven.repo.local=$OPENSHIFT_TMP_DIR/m2" export HOME="$OPENSHIFT_TMP_DIR/local" +export NPM_CONFIG_ARCH="x64" + npm install npm export PATH="$OPENSHIFT_REPO_DIR/node_modules/.bin:$PATH" -mvn clean package +mvn clean package -DskipTests -Dos.arch=x64 diff --git a/.openshift/cron/README.cron b/.openshift/cron/README.cron deleted file mode 100644 index ac77f787..00000000 --- a/.openshift/cron/README.cron +++ /dev/null @@ -1,27 +0,0 @@ -Run scripts or jobs on a periodic basis -======================================= -Any scripts or jobs added to the minutely, hourly, daily, weekly or monthly -directories will be run on a scheduled basis (frequency is as indicated by the -name of the directory) using run-parts. - -run-parts ignores any files that are hidden or dotfiles (.*) or backup -files (*~ or *,) or named *.{rpmsave,rpmorig,rpmnew,swp,cfsaved} - -The presence of two specially named files jobs.deny and jobs.allow controls -how run-parts executes your scripts/jobs. - jobs.deny ===> Prevents specific scripts or jobs from being executed. - jobs.allow ===> Only execute the named scripts or jobs (all other/non-named - scripts that exist in this directory are ignored). - -The principles of jobs.deny and jobs.allow are the same as those of cron.deny -and cron.allow and are described in detail at: - http://docs.redhat.com/docs/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/ch-Automating_System_Tasks.html#s2-autotasks-cron-access - -See: man crontab or above link for more details and see the the weekly/ - directory for an example. - -PLEASE NOTE: The Cron cartridge must be installed in order to run the configured jobs. - -For more information about cron, consult the documentation: -http://openshift.github.io/documentation/oo_cartridge_guide.html#cron -http://openshift.github.io/documentation/oo_user_guide.html#cron diff --git a/diy/index.html b/diy/index.html deleted file mode 100644 index 58caef0b..00000000 --- a/diy/index.html +++ /dev/null @@ -1,279 +0,0 @@ - - - - - - Welcome to OpenShift - - - - -
-
-

Welcome to your Do-It-Yourself application on OpenShift

-
-

- Do-It-Yourself is an experimental cartridge that provides a way to try unsupported languages, frameworks, and middleware on OpenShift. - To get started, add your framework of choice and modify .openshift/action_hooks/{start, stop} - to start and stop your application. - The only restriction is that your application should bind to $OPENSHIFT_DIY_IP:8080 - Don't forget to stop the existing server that is running before you push your stop file. -

- -
-
-
-

Deploying code changes

-

OpenShift uses the Git version control system for your source code, and grants you access to it via the Secure Shell (SSH) protocol. In order to upload and download code to your application you need to give us your public SSH key. You can upload it within the web console or install the RHC command line tool and run rhc setup to generate and upload your key automatically.

- -

Working in your local Git repository

-

If you created your application from the command line and uploaded your SSH key, rhc will automatically download a copy of that source code repository (Git calls this 'cloning') to your local system.

- -

If you created the application from the web console, you'll need to manually clone the repository to your local system. Copy the application's source code Git URL and then run:

- -
$ git clone <git_url> <directory_to_create>
-
-# Within your project directory
-# Commit your changes and push to OpenShift
-
-$ git commit -a -m 'Some commit message'
-$ git push
- - - -
- -
-
- -

Managing your application

- -

Web Console

-

You can use the OpenShift web console to enable additional capabilities via cartridges, add collaborator access authorizations, designate custom domain aliases, and manage domain memberships.

- -

Command Line Tools

-

Installing the OpenShift RHC client tools allows you complete control of your cloud environment. Read more on how to manage your application from the command line in our User Guide. -

- -

Development Resources

- - - -
-
- - -
- -
-
- - - diff --git a/diy/testrubyserver.rb b/diy/testrubyserver.rb deleted file mode 100755 index e9ef1156..00000000 --- a/diy/testrubyserver.rb +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/env ruby -require 'webrick' -include WEBrick - -config = {} -config.update(:Port => 8080) -config.update(:BindAddress => ARGV[0]) -config.update(:DocumentRoot => ARGV[1]) -server = HTTPServer.new(config) -['INT', 'TERM'].each {|signal| - trap(signal) {server.shutdown} -} - -server.start diff --git a/misc/.gitkeep b/misc/.gitkeep deleted file mode 100644 index e69de29b..00000000 diff --git a/pom.xml b/pom.xml index f9b8feb2..d238050f 100644 --- a/pom.xml +++ b/pom.xml @@ -323,4 +323,4 @@ test - \ No newline at end of file +