Skip to content
This repository has been archived by the owner on Sep 13, 2022. It is now read-only.

Add initial JenkinsFile for redux #528

Merged
merged 4 commits into from Jun 18, 2018
Merged

Add initial JenkinsFile for redux #528

merged 4 commits into from Jun 18, 2018

Conversation

cpanato
Copy link
Contributor

@cpanato cpanato commented Jun 11, 2018

Summary

In order to test I need get this merged :)

Ticket Link

jira: https://mattermost.atlassian.net/browse/MM-7495

@cpanato cpanato added the 2: Dev Review Requires review by a core commiter label Jun 11, 2018
lieut-data
lieut-data previously approved these changes Jun 11, 2018
Copy link
Member

@lieut-data lieut-data left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a lot of context into what this is used for, but I get the gist and it seems fine :)

tar -zxf mattermost-enterprise-linux-amd64.tar.gz

cd mattermost
sed -i'' 's|mmuser:mostest@tcp(dockerhost:3306)/mattermost_test?charset=utf8mb4,utf8|root:passwd@tcp(localhost:3306)/'${BUILD_TAG}'?charset=utf8mb4,utf8|g' config/config.json;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suspect this is copied from other such files, but I wonder if we should adopt a less brittle approach and just export the desired variables to the environment vs. messing with the config.json syntax:

export MM_SQLSETTINGS_DATASOURCE="..."
export MM_TEAMSETTINGS_ENABLEOPENSERVER="true"
...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agree

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done and thanks so much for this valuable info!

@cpanato
Copy link
Contributor Author

cpanato commented Jun 11, 2018

actually not! :) i will test and see any improvements/issues

jwilander
jwilander previously approved these changes Jun 12, 2018
@jwilander jwilander added 4: Reviews Complete All reviewers have approved the pull request and removed 2: Dev Review Requires review by a core commiter labels Jun 12, 2018
@cpanato cpanato dismissed stale reviews from lieut-data and jwilander June 13, 2018 13:49

updates and new file

@cpanato
Copy link
Contributor Author

cpanato commented Jun 13, 2018

@lieut-data @jwilander PTAL, i've update based in the tests using the pipeline.

however, to test using the real server we need to fix some tests it is failing in the beginning

> mattermost-redux@1.2.0 test-no-mock /home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux
> TEST_SERVER=1 NOCK_OFF=true NODE_ENV=test mocha --opts test/mocha.opts

/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/test/test_helper.js:197
                creator_id: _this.basicUser.id,
                                            ^

TypeError: Cannot read property 'id' of null
    at TestHelper.testCommand (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/test/test_helper.js:194:40)
    at Suite.<anonymous> (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/test/selectors/integrations.test.js:22:66)
    at Object.create (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/mocha/lib/interfaces/common.js:112:19)
    at context.describe.context.context (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/mocha/lib/interfaces/bdd.js:44:27)
    at Object.<anonymous> (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/test/selectors/integrations.test.js:10:1)
    at Module._compile (module.js:652:30)
    at loader (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/babel-register/lib/node.js:144:5)
    at Object.require.extensions.(anonymous function) [as .js] (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/babel-register/lib/node.js:154:7)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at /home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/mocha/lib/mocha.js:253:27
    at Array.forEach (<anonymous>)
    at Mocha.loadFiles (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/mocha/lib/mocha.js:250:14)
    at Mocha.run (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/mocha/lib/mocha.js:577:10)
    at Object.<anonymous> (/home/ubuntu/jenkins/workspace/mmrdx/test-pipe-redux/node_modules/mocha/bin/_mocha:591:18)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Function.Module.runMain (module.js:693:10)
    at startup (bootstrap_node.js:191:16)
    at bootstrap_node.js:612:3
npm ERR! code ELIFECYCLE

Copy link
Member

@lieut-data lieut-data left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Re: broken tests, I do recall running into this a while back. I'd suggest filing a new issue to fix same and we can investigate: there's a bunch of work to be done there.

@cpanato
Copy link
Contributor Author

cpanato commented Jun 13, 2018

ok, then I will comment the part that tests using a live server. ok @lieut-data ?

@lieut-data
Copy link
Member

I'm personally ok with that! @jwilander, any objections?

@jwilander
Copy link
Member

Yes that's good with me 👍

@cpanato
Copy link
Contributor Author

cpanato commented Jun 15, 2018

@jwilander @lieut-data set only the master branch to run the tests with a live server.

@jwilander
Copy link
Member

@cpanato feel free to merge

@cpanato cpanato merged commit 1d4ec99 into mattermost:master Jun 18, 2018
@cpanato cpanato deleted the add_jenkinsfile branch June 18, 2018 13:05
chetanyakan pushed a commit to brightscout-alpha/mattermost-redux that referenced this pull request Feb 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
4: Reviews Complete All reviewers have approved the pull request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants