Merge branch 'master' into data-source-settings-to-react

This commit is contained in:
Peter Holmberg
2018-11-01 13:52:53 +01:00
198 changed files with 6366 additions and 2577 deletions

View File

@@ -76,7 +76,7 @@ if [ -d '/tmp/phantomjs/windows' ]; then
cp /tmp/phantomjs/windows/phantomjs.exe tools/phantomjs/phantomjs.exe
rm tools/phantomjs/phantomjs
else
echo 'PhantomJS binaries for darwin missing!'
echo 'PhantomJS binaries for Windows missing!'
fi
go run build.go -goos windows -pkg-arch amd64 ${OPT} package-only

View File

@@ -0,0 +1,5 @@
FROM circleci/python:2.7-stretch
RUN sudo pip install awscli && \
curl https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-222.0.0-linux-x86_64.tar.gz | \
sudo tar xvzf - -C /opt

View File

@@ -0,0 +1,7 @@
#!/bin/bash
_version="1.0.0"
_tag="grafana/grafana-ci-deploy:${_version}"
docker build -t $_tag .
docker push $_tag

View File

@@ -22,13 +22,13 @@ var versionRe = regexp.MustCompile(`grafana-(.*)(\.|_)(arm64|armhfp|aarch64|armv
var debVersionRe = regexp.MustCompile(`grafana_(.*)_(arm64|armv7|armhf|amd64)\.deb`)
var builds = []build{}
var architectureMapping = map[string]string{
"armv7":"armv7",
"armhfp":"armv7",
"armhf":"armv7",
"arm64":"arm64",
"aarch64":"arm64",
"amd64":"amd64",
"x86_64":"amd64",
"armv7": "armv7",
"armhfp": "armv7",
"armhf": "armv7",
"arm64": "arm64",
"aarch64": "arm64",
"amd64": "amd64",
"x86_64": "amd64",
}
func main() {
@@ -78,7 +78,7 @@ func mapPackage(path string, name string, shaBytes []byte) (build, error) {
if len(result) > 0 {
version = string(result[1])
log.Printf("Version detected: %v", version)
} else if (len(debResult) > 0) {
} else if len(debResult) > 0 {
version = string(debResult[1])
} else {
return build{}, fmt.Errorf("Unable to figure out version from '%v'", name)
@@ -124,6 +124,9 @@ func mapPackage(path string, name string, shaBytes []byte) (build, error) {
}
func packageWalker(path string, f os.FileInfo, err error) error {
if err != nil {
log.Printf("error: %v", err)
}
if f.Name() == "dist" || strings.Contains(f.Name(), "sha256") || strings.Contains(f.Name(), "latest") {
return nil
}
@@ -134,7 +137,6 @@ func packageWalker(path string, f os.FileInfo, err error) error {
}
build, err := mapPackage(path, f.Name(), shaBytes)
if err != nil {
log.Printf("Could not map metadata from package: %v", err)
return nil

View File

@@ -17,8 +17,8 @@ module.exports = function (grunt) {
grunt.registerTask('precommit', [
'sasslint',
'exec:tslint',
'exec:tsc',
'newer:exec:tslint',
'newer:exec:tsc',
'no-only-tests'
]);

View File

@@ -4,7 +4,7 @@ module.exports = function(config) {
var task = {
release: {
options: {
archive: '<%= destDir %>/<%= pkg.name %>-<%= pkg.version %>.<%= platform %>-<%= arch %>.tar.gz'
archive: '<%= destDir %>/<%= pkg.name %><%= enterprise ? "-enterprise" : "" %>-<%= pkg.version %>.<%= platform %>-<%= arch %>.tar.gz'
},
files : [
{
@@ -23,7 +23,7 @@ module.exports = function(config) {
};
if (config.platform === 'windows') {
task.release.options.archive = '<%= destDir %>/<%= pkg.name %>-<%= pkg.version %>.<%= platform %>-<%= arch %>.zip';
task.release.options.archive = '<%= destDir %>/<%= pkg.name %><%= enterprise ? "-enterprise" : "" %>-<%= pkg.version %>.<%= platform %>-<%= arch %>.zip';
}
return task;

View File

@@ -2,8 +2,14 @@ module.exports = function (config, grunt) {
'use strict';
return {
tslint: 'node ./node_modules/tslint/lib/tslintCli.js -c tslint.json --project ./tsconfig.json',
tsc: 'yarn tsc --noEmit',
tslint: {
command: 'node ./node_modules/tslint/lib/tslintCli.js -c tslint.json --project ./tsconfig.json',
src: ['public/app/**/*.ts*'],
},
tsc: {
command: 'yarn tsc --noEmit',
src: ['public/app/**/*.ts*'],
},
jest: 'node ./node_modules/jest-cli/bin/jest.js --maxWorkers 2',
webpack: 'node ./node_modules/webpack/bin/webpack.js --config scripts/webpack/webpack.prod.js',
};

View File

@@ -16,7 +16,7 @@ module.exports = {
publicPath: "public/build/",
},
resolve: {
extensions: ['.ts', '.tsx', '.es6', '.js', '.json'],
extensions: ['.ts', '.tsx', '.es6', '.js', '.json', '.svg'],
alias: {
},
modules: [