Permalink
Browse files

Merge pull request #531 from amazeeio/v0.16.0

V0.16.0
  • Loading branch information...
Schnitzel committed Jul 31, 2018
2 parents 8e7d5cb + 55982fc commit 61f3b2bd2a2477b442e3f895af4b22a4fda0a762
Showing with 7,970 additions and 9,063 deletions.
  1. +2 −0 .eslintignore
  2. +2 −5 .flowconfig
  3. +7 −0 .vscode/extensions.json
  4. +10 −2 .vscode/settings.json
  5. +1 −5 Makefile
  6. +1 −1 cli/.eslintignore
  7. +1 −1 cli/.gitignore
  8. +8 −8 cli/README.md
  9. +10 −0 cli/bin/lagu.js
  10. +197 −19 cli/data/schema.graphql
  11. +2,069 −327 cli/data/schema.json
  12. +0 −510 cli/flow-typed/npm/jest_v20.x.x.js
  13. +0 −778 cli/flow-typed/npm/ramda_v0.x.x.js
  14. +1 −1 cli/jest.config.js
  15. +36 −31 cli/package.json
  16. +3 −0 cli/scripts/execute.js
  17. +234 −0 cli/src/__tests__/__snapshots__/e2e.test.js.snap
  18. +5 −45 cli/src/__tests__/__snapshots__/printErrors.test.js.snap
  19. +238 −0 cli/src/__tests__/e2e.test.js
  20. +1 −0 cli/src/__tests__/fixtures/.gitignore
  21. 0 cli/src/__tests__/fixtures/.gitkeep
  22. +1 −31 cli/src/__tests__/printErrors.test.js
  23. +12 −6 cli/src/__tests__/query.test.js
  24. +0 −102 cli/src/cli.js
  25. +75 −0 cli/src/cli/answerWithOption.js
  26. +28 −0 cli/src/cli/index.js
  27. +30 −0 cli/src/cli/promptUntilValidKeyPath.js
  28. +52 −0 cli/src/cli/visit.js
  29. +1 −3 cli/src/commands/__tests__/__snapshots__/customer.test.js.snap
  30. +27 −0 cli/src/commands/__tests__/__snapshots__/init.test.js.snap
  31. +1 −3 cli/src/commands/__tests__/__snapshots__/project.test.js.snap
  32. +1 −3 cli/src/commands/__tests__/__snapshots__/projects.test.js.snap
  33. +1 −1 cli/src/commands/__tests__/customer.test.js
  34. +16 −7 cli/src/commands/__tests__/init.test.js
  35. +4 −4 cli/src/commands/__tests__/project.test.js
  36. +1 −1 cli/src/commands/__tests__/projects.test.js
  37. +5 −5 cli/src/commands/customer.js
  38. +2 −2 cli/src/commands/environments.js
  39. +29 −4 cli/src/commands/index.js
  40. +198 −80 cli/src/commands/init.js
  41. +15 −8 cli/src/commands/login.js
  42. +7 −7 cli/src/commands/logout.js
  43. +76 −42 cli/src/commands/project.js
  44. +9 −13 cli/src/commands/projectCommands/__tests__/__snapshots__/project-create.test.js.snap
  45. +8 −10 cli/src/commands/projectCommands/__tests__/project-create.test.js
  46. +124 −114 cli/src/commands/projectCommands/create.js
  47. +138 −0 cli/src/commands/projectCommands/delete.js
  48. +16 −6 cli/src/commands/projects.js
  49. +9 −3 cli/src/config/__tests__/config.test.js
  50. +68 −0 cli/src/config/getApiConfig.js
  51. +50 −0 cli/src/config/getSshConfig.js
  52. +66 −15 cli/src/config/index.js
  53. +21 −33 cli/src/printErrors.js
  54. +15 −49 cli/src/query.js
  55. +26 −0 cli/src/ssh/getPrivateKeyPassphrase.js
  56. +38 −0 cli/src/ssh/getPrivateKeyPath.js
  57. +7 −0 cli/src/ssh/index.js
  58. +78 −0 cli/src/ssh/sshConnect.js
  59. +32 −0 cli/src/ssh/sshExec.js
  60. +2 −0 cli/src/util/__tests__/request.test.js
  61. +5 −6 cli/src/util/fs.js
  62. +2 −2 cli/src/util/request.js
  63. +0 −202 cli/src/util/ssh.js
  64. +1 −1 docs/using_lagoon/docker-compose_yml.md
  65. +36 −0 docs/using_lagoon/drupal/services/solr.md
  66. +19 −1 docs/using_lagoon/workflows.md
  67. 0 {services/auth-server → }/flow-typed/custom/emit.js
  68. +8 −4 flow-typed/custom/express_v4.16.x.js
  69. 0 {cli/flow-typed → flow-typed/custom}/mocha.js
  70. +2,111 −0 flow-typed/custom/ramda_v0.x.x.js
  71. +1 −1 {cli/flow-typed/npm → flow-typed/custom}/yargs_v10.x.x.js
  72. 0 {cli → }/flow-typed/npm/babel-cli_vx.x.x.js
  73. 0 {cli → }/flow-typed/npm/babel-core_vx.x.x.js
  74. 0 {cli → }/flow-typed/npm/babel-eslint_vx.x.x.js
  75. 0 {cli → }/flow-typed/npm/babel-jest_vx.x.x.js
  76. 0 {cli → }/flow-typed/npm/babel-plugin-syntax-async-functions_vx.x.x.js
  77. 0 {cli → }/flow-typed/npm/babel-plugin-transform-flow-strip-types_vx.x.x.js
  78. 0 {cli → }/flow-typed/npm/babel-plugin-transform-object-rest-spread_vx.x.x.js
  79. 0 {cli → }/flow-typed/npm/babel-plugin-transform-regenerator_vx.x.x.js
  80. 0 {cli → }/flow-typed/npm/babel-polyfill_vx.x.x.js
  81. 0 {cli → }/flow-typed/npm/babel-preset-es2015_vx.x.x.js
  82. +6 −8 {services/auth-server → }/flow-typed/npm/body-parser_v1.x.x.js
  83. 0 {cli → }/flow-typed/npm/chalk_v1.x.x.js
  84. 0 {cli → }/flow-typed/npm/co_vx.x.x.js
  85. 0 {cli → }/flow-typed/npm/eslint-plugin-flow-vars_vx.x.x.js
  86. 0 {cli → }/flow-typed/npm/eslint-plugin-flowtype_vx.x.x.js
  87. 0 {cli → }/flow-typed/npm/eslint-plugin-graphql_vx.x.x.js
  88. 0 {cli → }/flow-typed/npm/eslint_vx.x.x.js
  89. 0 {cli → }/flow-typed/npm/flow-bin_v0.x.x.js
  90. +339 −0 flow-typed/npm/inquirer_v1.x.x.js
  91. +203 −52 services/auth-server/flow-typed/npm/jest_v20.x.x.js → flow-typed/npm/jest_v22.x.x.js
  92. 0 {cli → }/flow-typed/npm/js-yaml_vx.x.x.js
  93. 0 {services/auth-server → }/flow-typed/npm/jsonwebtoken_vx.x.x.js
  94. 0 {cli → }/flow-typed/npm/lint-staged_vx.x.x.js
  95. 0 {services/auth-server → }/flow-typed/npm/morgan_vx.x.x.js
  96. 0 {services/auth-server → }/flow-typed/npm/nano_vx.x.x.js
  97. 0 {cli → }/flow-typed/npm/node-fetch_vx.x.x.js
  98. 0 {services/auth-server → }/flow-typed/npm/nodemon_vx.x.x.js
  99. 0 {cli → }/flow-typed/npm/pre-commit_vx.x.x.js
  100. 0 {services/auth-server → }/flow-typed/npm/prettier_vx.x.x.js
  101. 0 {cli → }/flow-typed/npm/rimraf_vx.x.x.js
  102. 0 {cli → }/flow-typed/npm/ssh2_vx.x.x.js
  103. 0 {services/auth-server → }/flow-typed/npm/sshpk_vx.x.x.js
  104. 0 {cli → }/flow-typed/npm/table_vx.x.x.js
  105. 0 {services/auth-server → }/flow-typed/npm/winston_vx.x.x.js
  106. +0 −61 images/centos7/Dockerfile
  107. +0 −19 images/centos7/README.md
  108. +0 −4 images/centos7/entrypoints/00-umask.sh
  109. +0 −7 images/centos7/entrypoints/10-passwd.sh
  110. +0 −39 images/centos7/entrypoints/50-dotenv.sh
  111. +0 −15 images/centos7/lagoon-entrypoints.sh
  112. +3 −0 images/commons/.bashrc
  113. +20 −23 images/mongo/Dockerfile
  114. +9 −0 images/php/cli/55-cli-helpers.sh
  115. +5 −0 images/php/cli/Dockerfile
  116. +11 −0 local-dev/api-data/api-data.gql
  117. +2 −1 mkdocs.yml
  118. +1 −1 node-packages/commons/package.json
  119. +3 −1 node-packages/commons/src/api.js
  120. +2 −2 node-packages/commons/src/jwt.js
  121. +3 −1 node-packages/eslint-config-lagoon-node/index.js
  122. +1 −1 node-packages/eslint-config-lagoon-node/package.json
  123. +6 −2 package.json
  124. +22 −18 services/api-db/docker-entrypoint-initdb.d/01-procedures.sql
  125. +0 −4 services/api/.prettierrc
  126. +1 −1 services/api/package.json
  127. +2 −0 services/api/src/app.js
  128. +18 −6 services/api/src/auth.js
  129. +2 −0 services/api/src/auth.test.js
  130. +1 −2 services/api/src/dao/customer.js
  131. +99 −68 services/api/src/dao/environment.js
  132. +3 −2 services/api/src/dao/index.js
  133. +16 −17 services/api/src/dao/notification.js
  134. +16 −7 services/api/src/dao/openshift.js
  135. +15 −6 services/api/src/dao/project.js
  136. +12 −12 services/api/src/dao/sshKey.js
  137. +0 −2 services/api/src/dao/sshKey.test.js
  138. +18 −5 services/api/src/index.js
  139. +2 −0 services/api/src/logger.js
  140. +23 −6 services/api/src/schema.js
  141. +2 −0 services/api/src/server.js
  142. +0 −108 services/auth-server/flow-typed/npm/babel-cli_vx.x.x.js
  143. +0 −227 services/auth-server/flow-typed/npm/babel-core_vx.x.x.js
  144. +0 −80 services/auth-server/flow-typed/npm/babel-eslint_vx.x.x.js
  145. +0 −32 services/auth-server/flow-typed/npm/babel-plugin-transform-flow-strip-types_vx.x.x.js
  146. +0 −32 services/auth-server/flow-typed/npm/babel-preset-es2015_vx.x.x.js
  147. +0 −45 services/auth-server/flow-typed/npm/eslint-plugin-flow-vars_vx.x.x.js
  148. +0 −326 services/auth-server/flow-typed/npm/eslint-plugin-flowtype_vx.x.x.js
  149. +0 −2,349 services/auth-server/flow-typed/npm/eslint_vx.x.x.js
  150. +0 −6 services/auth-server/flow-typed/npm/flow-bin_v0.x.x.js
  151. +0 −143 services/auth-server/flow-typed/npm/lint-staged_vx.x.x.js
  152. +0 −52 services/auth-server/flow-typed/npm/pre-commit_vx.x.x.js
  153. +0 −2,271 services/auth-server/flow-typed/npm/ramda_vx.x.x.js
  154. +0 −39 services/auth-server/flow-typed/npm/rimraf_vx.x.x.js
  155. +1 −1 services/auth-server/package.json
  156. +9 −2 services/auth-server/src/util/routing.js
  157. +3 −3 services/logs2rocketchat/src/types.js
  158. +39 −0 tests/tests/drupal/drush.yaml
  159. +754 −452 yarn.lock
View
@@ -0,0 +1,2 @@
**/flow-typed/
**/node_modules/
View
@@ -7,7 +7,7 @@
.*node_modules/node-uuid.*
<PROJECT_ROOT>/images/
<PROJECT_ROOT>/tests/
# Too many errors as of now. Enable again when errors fixed.
# Too many errors for now (as of June 2018). Enable again when errors fixed.
<PROJECT_ROOT>/services/hacky-rest2tasks-ui/
<PROJECT_ROOT>/services/logs2slack/
<PROJECT_ROOT>/services/openshiftbuilddeploy/
@@ -20,7 +20,4 @@
[include]
[libs]
flow-typed
cli/flow-typed
services/api/flow-typed
services/auth-server/flow-typed
flow-typed
View
@@ -0,0 +1,7 @@
{
"recommendations": [
"flowtype.flow-for-vscode",
"esbenp.prettier-vscode",
"dbaeumer.vscode-eslint"
]
}
View
@@ -1,5 +1,13 @@
// Place your settings in this file to overwrite default and user settings.
{
"eslint.workingDirectories": [
"./cli",
"./node-packages/commons",
"./services/auth-server"
],
"git.ignoreLimitWarning": true,
"javascript.validate.enable": false,
"git.ignoreLimitWarning": true
}
"files.trimTrailingWhitespace": true,
"prettier.eslintIntegration": true,
"flow.useNPMPackagedFlow": true
}
View
@@ -103,8 +103,7 @@ docker_publish_amazeeiolagoon_baseimages = docker tag $(CI_BUILD_TAG)/$(1) amaze
#######
####### Base Images are the base for all other images and are also published for clients to use during local development
images := centos7 \
oc \
images := oc \
mariadb \
mariadb-drupal \
postgres \
@@ -144,7 +143,6 @@ $(build-images):
# if the parent has been built
# 2. Dockerfiles of the Images itself, will cause make to rebuild the images if something has
# changed on the Dockerfiles
build/centos7: images/centos7/Dockerfile
build/mariadb: build/commons images/mariadb/Dockerfile
build/mariadb-drupal: build/mariadb images/mariadb-drupal/Dockerfile
build/postgres: build/commons images/postgres/Dockerfile
@@ -366,8 +364,6 @@ build/cli: build/ssh cli/Dockerfile
$(call docker_build,$(image),cli/Dockerfile,cli)
touch $@
build/local-git-server: build/centos7
# Image with ansible test
build/tests:
$(eval image = $(subst build/,,$@))
View
@@ -1,2 +1,2 @@
build/
flow-typed/
dist/
View
@@ -1,5 +1,5 @@
node_modules/
dist/
build/
.npmrc
.DS_Store
.lagoon.yml
View
@@ -1,4 +1,6 @@
# lagoon Command Line Interface
# lagu
> lagoon Command Line Interface
## Installation
@@ -14,14 +16,14 @@ yarn global add @lagoon/lagu
## Setup
The CLI needs a configuration file at `<project directory>/.lagoon.yml`, which can be created with [the `init` command](#lagoon-init):
The CLI needs a configuration file at `<project directory>/.lagoon.yml`, which can be created with [the `init` command](#lagu-init):
```sh
# Initialize project configuration
lagu init
$ lagu init
```
For more options, see the [`lagoon init` documentation](#lagoon-init).
For more options, see the [`lagu init` documentation](#lagu-init).
## Commands
@@ -64,7 +66,7 @@ Examples:
confirm with or prompt the user).
```
#### `lagoon init` Examples
#### `lagu init` Examples
```text
$ lagu init
@@ -136,11 +138,9 @@ Login successful
The `execute <cli command>` yarn script can be used to run CLI commands during development.
Additionally you want to add:
Additionally the following parameters should be set in the `.lagoon.yml` file. They can also be configured with the `init` command.
```yaml
api: http://localhost:3000
ssh: localhost:2020
```
to the `.lagoon.yml` file so that it uses the development api and ssh services
View
@@ -0,0 +1,10 @@
#!/usr/bin/env node
const importLocal = require('import-local');
// Try using locally installed version and fall back to global version
const localImportFailed = !importLocal(__filename);
if (localImportFailed) {
require('../build/cli').run();
}
Oops, something went wrong.

0 comments on commit 61f3b2b

Please sign in to comment.