pax_global_header00006660000000000000000000000064132053447310014514gustar00rootroot0000000000000052 comment=88df1a5950bf3cd9bffa1e0137ab6471c4546118 detect-libc-1.0.3/000077500000000000000000000000001320534473100136745ustar00rootroot00000000000000detect-libc-1.0.3/.circleci/000077500000000000000000000000001320534473100155275ustar00rootroot00000000000000detect-libc-1.0.3/.circleci/config.yml000066400000000000000000000006631320534473100175240ustar00rootroot00000000000000version: 2 jobs: build: machine: true #branches: #only: # - master steps: - run: name: Install required tools command: pip install prettytable - checkout - run: name: Pull test images (if possible) command: ./tests/integration/test.py pull || true - run: name: Run integration tests command: ./tests/integration/test.py run detect-libc-1.0.3/.gitignore000066400000000000000000000015641320534473100156720ustar00rootroot00000000000000# Logs logs *.log npm-debug.log* yarn-debug.log* yarn-error.log* # Runtime data pids *.pid *.seed *.pid.lock # Directory for instrumented libs generated by jscoverage/JSCover lib-cov # Coverage directory used by tools like istanbul coverage # nyc test coverage .nyc_output # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) .grunt # Bower dependency directory (https://bower.io/) bower_components # node-waf configuration .lock-wscript # Compiled binary addons (http://nodejs.org/api/addons.html) build/Release # Dependency directories node_modules/ jspm_packages/ # Typescript v1 declaration files typings/ # Optional npm cache directory .npm # Optional eslint cache .eslintcache # Optional REPL history .node_repl_history # Output of 'npm pack' *.tgz # Yarn Integrity file .yarn-integrity # dotenv environment variables file .env detect-libc-1.0.3/.npmignore000066400000000000000000000001241320534473100156700ustar00rootroot00000000000000.nyc_output .travis.yml coverage test.js node_modules /.circleci /tests/integration detect-libc-1.0.3/.travis.yml000066400000000000000000000011131320534473100160010ustar00rootroot00000000000000language: node_js matrix: include: - os: linux dist: trusty sudo: false node_js: "0.10" script: node -e 'require("assert").strictEqual(false, require("./").isNonGlibcLinux)' - os: linux dist: trusty sudo: false node_js: "0.12" script: node -e 'require("assert").strictEqual(false, require("./").isNonGlibcLinux)' - os: linux dist: trusty sudo: false node_js: "4" - os: linux dist: trusty sudo: false node_js: "6" - os: linux dist: trusty sudo: false node_js: "8" detect-libc-1.0.3/LICENSE000066400000000000000000000261351320534473100147100ustar00rootroot00000000000000 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright {yyyy} {name of copyright owner} Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. detect-libc-1.0.3/README.md000066400000000000000000000045531320534473100151620ustar00rootroot00000000000000# detect-libc Node.js module to detect the C standard library (libc) implementation family and version in use on a given Linux system. Provides a value suitable for use with the `LIBC` option of [prebuild](https://www.npmjs.com/package/prebuild), [prebuild-ci](https://www.npmjs.com/package/prebuild-ci) and [prebuild-install](https://www.npmjs.com/package/prebuild-install), therefore allowing build and provision of pre-compiled binaries for musl-based Linux e.g. Alpine as well as glibc-based. Currently supports libc detection of `glibc` and `musl`. ## Install ```sh npm install detect-libc ``` ## Usage ### API ```js const { GLIBC, MUSL, family, version, isNonGlibcLinux } = require('detect-libc'); ``` * `GLIBC` is a String containing the value "glibc" for comparison with `family`. * `MUSL` is a String containing the value "musl" for comparison with `family`. * `family` is a String representing the system libc family. * `version` is a String representing the system libc version number. * `isNonGlibcLinux` is a Boolean representing whether the system is a non-glibc Linux, e.g. Alpine. ### detect-libc command line tool When run on a Linux system with a non-glibc libc, the child command will be run with the `LIBC` environment variable set to the relevant value. On all other platforms will run the child command as-is. The command line feature requires `spawnSync` provided by Node v0.12+. ```sh detect-libc child-command ``` ## Integrating with prebuild ```json "scripts": { "install": "detect-libc prebuild-install || node-gyp rebuild", "test": "mocha && detect-libc prebuild-ci" }, "dependencies": { "detect-libc": "^1.0.2", "prebuild-install": "^2.2.0" }, "devDependencies": { "prebuild": "^6.2.1", "prebuild-ci": "^2.2.3" } ``` ## Licence Copyright 2017 Lovell Fuller Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at [http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0.html) Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. detect-libc-1.0.3/bin/000077500000000000000000000000001320534473100144445ustar00rootroot00000000000000detect-libc-1.0.3/bin/detect-libc.js000077500000000000000000000005631320534473100171700ustar00rootroot00000000000000#!/usr/bin/env node 'use strict'; var spawnSync = require('child_process').spawnSync; var libc = require('../'); var spawnOptions = { env: process.env, shell: true, stdio: 'inherit' }; if (libc.isNonGlibcLinux) { spawnOptions.env.LIBC = process.env.LIBC || libc.family; } process.exit(spawnSync(process.argv[2], process.argv.slice(3), spawnOptions).status); detect-libc-1.0.3/lib/000077500000000000000000000000001320534473100144425ustar00rootroot00000000000000detect-libc-1.0.3/lib/detect-libc.js000066400000000000000000000042061320534473100171610ustar00rootroot00000000000000'use strict'; var platform = require('os').platform(); var spawnSync = require('child_process').spawnSync; var readdirSync = require('fs').readdirSync; var GLIBC = 'glibc'; var MUSL = 'musl'; var spawnOptions = { encoding: 'utf8', env: process.env }; if (!spawnSync) { spawnSync = function () { return { status: 126, stdout: '', stderr: '' }; }; } function contains (needle) { return function (haystack) { return haystack.indexOf(needle) !== -1; }; } function versionFromMuslLdd (out) { return out.split(/[\r\n]+/)[1].trim().split(/\s/)[1]; } function safeReaddirSync (path) { try { return readdirSync(path); } catch (e) {} return []; } var family = ''; var version = ''; var method = ''; if (platform === 'linux') { // Try getconf var glibc = spawnSync('getconf', ['GNU_LIBC_VERSION'], spawnOptions); if (glibc.status === 0) { family = GLIBC; version = glibc.stdout.trim().split(' ')[1]; method = 'getconf'; } else { // Try ldd var ldd = spawnSync('ldd', ['--version'], spawnOptions); if (ldd.status === 0 && ldd.stdout.indexOf(MUSL) !== -1) { family = MUSL; version = versionFromMuslLdd(ldd.stdout); method = 'ldd'; } else if (ldd.status === 1 && ldd.stderr.indexOf(MUSL) !== -1) { family = MUSL; version = versionFromMuslLdd(ldd.stderr); method = 'ldd'; } else { // Try filesystem (family only) var lib = safeReaddirSync('/lib'); if (lib.some(contains('-linux-gnu'))) { family = GLIBC; method = 'filesystem'; } else if (lib.some(contains('libc.musl-'))) { family = MUSL; method = 'filesystem'; } else if (lib.some(contains('ld-musl-'))) { family = MUSL; method = 'filesystem'; } else { var usrSbin = safeReaddirSync('/usr/sbin'); if (usrSbin.some(contains('glibc'))) { family = GLIBC; method = 'filesystem'; } } } } } var isNonGlibcLinux = (family !== '' && family !== GLIBC); module.exports = { GLIBC: GLIBC, MUSL: MUSL, family: family, version: version, method: method, isNonGlibcLinux: isNonGlibcLinux }; detect-libc-1.0.3/package.json000066400000000000000000000014231320534473100161620ustar00rootroot00000000000000{ "name": "detect-libc", "version": "1.0.3", "description": "Node.js module to detect the C standard library (libc) implementation family and version", "main": "lib/detect-libc.js", "bin": { "detect-libc": "./bin/detect-libc.js" }, "scripts": { "test": "semistandard && nyc --reporter=lcov ava" }, "repository": { "type": "git", "url": "git://github.com/lovell/detect-libc" }, "keywords": [ "libc", "glibc", "musl" ], "author": "Lovell Fuller ", "contributors": [ "Niklas Salmoukas " ], "license": "Apache-2.0", "devDependencies": { "ava": "^0.23.0", "nyc": "^11.3.0", "proxyquire": "^1.8.0", "semistandard": "^11.0.0" }, "engines": { "node": ">=0.10" } } detect-libc-1.0.3/test.js000066400000000000000000000145151320534473100152170ustar00rootroot00000000000000'use strict'; const ava = require('ava'); const proxyquire = require('proxyquire') .noCallThru() .noPreserveCache(); ava('linux glibc is detected', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function () { return { status: 0, stdout: 'glibc 1.23\n' }; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.GLIBC, libc.family); t.is('1.23', libc.version); t.is('getconf', libc.method); t.false(libc.isNonGlibcLinux); }); ava('linux musl is detected via ldd exit 0', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function (command) { return command === 'getconf' ? { status: 64, stdout: 'getconf: GNU_LIBC_VERSION: unknown variable\n' } : { status: 0, stdout: 'musl libc (x86_64)\nVersion 1.2.3\nDynamic Program Loader\nUsage: ldd [options] [--] pathname' }; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.MUSL, libc.family); t.is('1.2.3', libc.version); t.is('ldd', libc.method); t.true(libc.isNonGlibcLinux); }); ava('linux musl is detected via ldd exit 1', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function (command) { return command === 'getconf' ? { status: 64, stdout: 'getconf: GNU_LIBC_VERSION: unknown variable\n' } : { status: 1, stderr: 'musl libc (x86_64)\nVersion 1.2.3\nDynamic Program Loader\nUsage: ldd [options] [--] pathname' }; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.MUSL, libc.family); t.is('1.2.3', libc.version); t.is('ldd', libc.method); t.true(libc.isNonGlibcLinux); }); ava('darwin is ignored', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'darwin'; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is('', libc.family); t.is('', libc.version); t.is('', libc.method); t.false(libc.isNonGlibcLinux); }); ava('win32 is ignored', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'win32'; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is('', libc.family); t.is('', libc.version); t.is('', libc.method); t.false(libc.isNonGlibcLinux); }); ava('Linux detect glibc from /lib filesystem', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function () { return { status: -1 }; } }, fs: { readdirSync: function () { return ['init', 'modprobe.d', 'modules', 'resolvconf', 'systemd', 'udev', 'x86_64-linux-gnu', 'xtables']; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.GLIBC, libc.family); t.is('', libc.version); t.is('filesystem', libc.method); t.false(libc.isNonGlibcLinux); }); ava('Linux detect glibc from /usr filesystem', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function () { return { status: -1 }; } }, fs: { readdirSync: function (path) { return path === '/usr/sbin' ? ['glibc-post-wrapper'] : []; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.GLIBC, libc.family); t.is('', libc.version); t.is('filesystem', libc.method); t.false(libc.isNonGlibcLinux); }); ava('Linux detect musl from filesystem', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function () { return { status: -1 }; } }, fs: { readdirSync: function () { return ['apk', 'firmware', 'ld-musl-x86_64.so.1', 'libc.musl-x86_64.so.1', 'libz.so.1', 'libz.so.1.2.11', 'mdev']; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.MUSL, libc.family); t.is('', libc.version); t.is('filesystem', libc.method); t.true(libc.isNonGlibcLinux); }); ava('NodeOS detect musl from filesystem', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function () { return { status: -1 }; } }, fs: { readdirSync: function () { return ['ld-musl-x86_64.so.1', 'libc.so', 'libfuse.so', 'libfuse.so.2', 'libfuse.so.2.9.7', 'libgcc_s.so.1', 'libstdc++.so.6', 'libstdc++.so.6.0.21', 'node_modules']; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is(libc.MUSL, libc.family); t.is('', libc.version); t.is('filesystem', libc.method); t.true(libc.isNonGlibcLinux); }); ava('Linux fail to detect from filesystem', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: function () { return { status: -1 }; } }, fs: { readdirSync: function () { return []; } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is('', libc.family); t.is('', libc.version); t.is('', libc.method); t.false(libc.isNonGlibcLinux); }); ava('Linux minimal, without spawnSync or /usr/sbin', function (t) { t.plan(6); const libc = proxyquire('./', { os: { platform: function () { return 'linux'; } }, child_process: { spawnSync: undefined }, fs: { readdirSync: function () { throw new Error(); } } }); t.is('glibc', libc.GLIBC); t.is('musl', libc.MUSL); t.is('', libc.family); t.is('', libc.version); t.is('', libc.method); t.false(libc.isNonGlibcLinux); }); detect-libc-1.0.3/tests/000077500000000000000000000000001320534473100150365ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/000077500000000000000000000000001320534473100173615ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/README.md000066400000000000000000000005101320534473100206340ustar00rootroot00000000000000# Requirements The following tools are required to run the integration tests successfully. * Python 2.7, prettytable (`pip install prettytable`) * Docker # Usage ```sh # prepare images (e.g. on dev machine) ./test.py build ./test.py push # execute tests (e.g. within CI) ./test.py pull ./test.py run # help ./test.py -h ``` detect-libc-1.0.3/tests/integration/config.json000066400000000000000000000001061320534473100215160ustar00rootroot00000000000000{ "registry": "quay.io/core_process/detect-libc-integration-test" } detect-libc-1.0.3/tests/integration/probe.js000066400000000000000000000014311320534473100210250ustar00rootroot00000000000000var fs = require('fs'); var libc = require('../../lib/detect-libc.js'); var result = { }; result['libc.family'] = libc.family || 'unknown'; result['libc.version'] = libc.version || 'unknown'; result['detect.method'] = libc.method || 'unknown'; result['node.version'] = process.versions.node; var osRelease = (fs.existsSync('/etc/os-release') ? fs.readFileSync('/etc/os-release', 'utf8') : '' ) .split('\n') .filter(function (item) { return item.indexOf('=') !== -1; }) .map(function (item) { return item.split('=', 2); }) .reduce(function (obj, item) { obj[item[0].trim()] = item[1].trim().replace(/^"(.+)"$/, '$1'); return obj; }, { }); result['dist.name'] = osRelease.PRETTY_NAME || 'unknown'; console.log('result=' + JSON.stringify(result)); detect-libc-1.0.3/tests/integration/spec.json000066400000000000000000000131521320534473100212100ustar00rootroot00000000000000{ "ubuntu:all-nodejs-versions": { "dist": { "16.04": { "$libc.version": "2.23", "$dist.name": "Ubuntu 16.04.3 LTS" } }, "node": { "0.12.x": { "$detect.method": "getconf", "$node.version": "0.12.18" }, "4.x": { "$detect.method": "getconf", "$node.version": "4.8.5" }, "6.x": { "$detect.method": "getconf", "$node.version": "6.11.5" } }, "$libc.family": "glibc" }, "alpinelinux": { "dist": { "3.2": { "$libc.version": "1.1.11", "$dist.name": "Alpine Linux v3.2" }, "3.3": { "$libc.version": "1.1.12", "$dist.name": "Alpine Linux v3.3" }, "3.4": { "$libc.version": "1.1.14", "$dist.name": "Alpine Linux v3.4" }, "3.5": { "$libc.version": "1.1.15", "$dist.name": "Alpine Linux v3.5" }, "3.6": { "$libc.version": "1.1.16", "$dist.name": "Alpine Linux v3.6" } }, "node": { "0.10.x": { "$detect.method": "filesystem", "$libc.version": "unknown", "$node.version": "0.10.48" }, "8.x": { "$detect.method": "ldd", "$node.version": "8.8.1" } }, "$libc.family": "musl" }, "debian:nodejs-0.10.x": { "dist": { "wheezy": { "$dist.name": "Debian GNU/Linux 7 (wheezy)" }, "jessie": { "$dist.name": "Debian GNU/Linux 8 (jessie)" } }, "node": { "0.10.x": { "$detect.method": "filesystem", "$libc.version": "unknown", "$node.version": "0.10.48" } }, "$libc.family": "glibc" }, "debian:nodejs-8.x": { "dist": { "jessie": { "$libc.version": "2.19", "$dist.name": "Debian GNU/Linux 8 (jessie)" }, "stretch": { "$libc.version": "2.24", "$dist.name": "Debian GNU/Linux 9 (stretch)" } }, "node": { "8.x": { "$detect.method": "getconf", "$node.version": "8.8.1" } }, "$libc.family": "glibc" }, "ubuntu:nodejs-0.10.x": { "dist": { "14.04": { "$dist.name": "Ubuntu 14.04.5 LTS" }, "16.04": { "$dist.name": "Ubuntu 16.04.3 LTS" } }, "node": { "0.10.x": { "$detect.method": "filesystem", "$libc.version": "unknown", "$node.version": "0.10.48" } }, "$libc.family": "glibc" }, "ubuntu:nodejs-8.x": { "dist": { "14.04": { "$libc.version": "2.19", "$dist.name": "Ubuntu 14.04.5 LTS" }, "16.04": { "$libc.version": "2.23", "$dist.name": "Ubuntu 16.04.3 LTS" }, "17.04": { "$libc.version": "2.24", "$dist.name": "Ubuntu 17.04" }, "17.10": { "$libc.version": "2.26", "$dist.name": "Ubuntu 17.10" } }, "node": { "8.x": { "$detect.method": "getconf", "$node.version": "8.8.1" } }, "$libc.family": "glibc" }, "centos": { "dist": { "6.6": { "$libc.version": "2.12", "$dist.name": "unknown" }, "6.7": { "$libc.version": "2.12", "$dist.name": "unknown" }, "6.8": { "$libc.version": "2.12", "$dist.name": "unknown" }, "6.9": { "$libc.version": "2.12", "$dist.name": "unknown" }, "7.0": { "$libc.version": "2.17", "$dist.name": "CentOS Linux 7 (Core)" }, "7.1": { "$libc.version": "2.17", "$dist.name": "CentOS Linux 7 (Core)" }, "7.2": { "$libc.version": "2.17", "$dist.name": "CentOS Linux 7 (Core)" }, "7.3": { "$libc.version": "2.17", "$dist.name": "CentOS Linux 7 (Core)" }, "7.4": { "$libc.version": "2.17", "$dist.name": "CentOS Linux 7 (Core)" } }, "node": { "0.10.x": { "$detect.method": "filesystem", "$libc.version": "unknown", "$node.version": "0.10.46" }, "8.x": { "$detect.method": "getconf", "$node.version": "8.8.1" } }, "$libc.family": "glibc" }, "oraclelinux": { "dist": { "6.6": { "$libc.version": "2.12", "$dist.name": "unknown" }, "6.7": { "$libc.version": "2.12", "$dist.name": "Oracle Linux Server 6.7" }, "6.8": { "$libc.version": "2.12", "$dist.name": "Oracle Linux Server 6.8" }, "6.9": { "$libc.version": "2.12", "$dist.name": "Oracle Linux Server 6.9" }, "7.0": { "$libc.version": "2.17", "$dist.name": "Oracle Linux Server 7.0" }, "7.1": { "$libc.version": "2.17", "$dist.name": "Oracle Linux Server 7.1" }, "7.2": { "$libc.version": "2.17", "$dist.name": "Oracle Linux Server 7.2" }, "7.3": { "$libc.version": "2.17", "$dist.name": "Oracle Linux Server 7.3" }, "7.4": { "$libc.version": "2.17", "$dist.name": "Oracle Linux Server 7.4" } }, "node": { "0.10.x": { "$detect.method": "filesystem", "$libc.version": "unknown", "$node.version": "0.10.46" }, "8.x": { "$detect.method": "getconf", "$node.version": "8.9.0" } }, "$libc.family": "glibc" }, "amazonlinux": { "dist": { "2016.09": { "$libc.version": "2.17", "$dist.name": "Amazon Linux AMI 2016.09" }, "2017.03": { "$libc.version": "2.17", "$dist.name": "Amazon Linux AMI 2017.03" }, "2017.09": { "$libc.version": "2.17", "$dist.name": "Amazon Linux AMI 2017.09" } }, "node": { "0.10.x": { "$detect.method": "filesystem", "$libc.version": "unknown", "$node.version": "0.10.46" }, "8.x": { "$detect.method": "getconf", "$node.version": "8.9.0" } }, "$libc.family": "glibc" }, "opensuse": { "dist": { "42.2": { "$libc.version": "2.22", "$dist.name": "openSUSE Leap 42.2", "$node.version": "4.8.4" }, "42.3": { "$libc.version": "2.22", "$dist.name": "openSUSE Leap 42.3", "$node.version": "4.8.4" }, "tumbleweed": { "$libc.version": "2.26", "$dist.name": "openSUSE Tumbleweed", "$node.version": "4.8.5" } }, "node": { "4.x": { "$detect.method": "getconf" } }, "$libc.family": "glibc" }, "minimal": { "dist": { "rmg": { "$detect.method": "filesystem", "$libc.family": "glibc", "$libc.version": "unknown", "$dist.name": "unknown", "$node.version": "8.8.1" } }, "node": { "8.x": { } } } } detect-libc-1.0.3/tests/integration/spec/000077500000000000000000000000001320534473100203135ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/000077500000000000000000000000001320534473100226435ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-0.10.x/000077500000000000000000000000001320534473100247475ustar00rootroot00000000000000alpinelinux-3.2-nodejs-0.10.x.dockerfile000066400000000000000000000032521320534473100336550ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-0.10.xFROM alpine:3.2 ENV NODE_VERSION 0.10.48 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ tar xz \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && export CFLAGS="-D__USE_MISC" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.3-nodejs-0.10.x.dockerfile000066400000000000000000000032521320534473100336560ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-0.10.xFROM alpine:3.3 ENV NODE_VERSION 0.10.48 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ tar xz \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && export CFLAGS="-D__USE_MISC" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.4-nodejs-0.10.x.dockerfile000066400000000000000000000032311320534473100336540ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-0.10.xFROM alpine:3.4 ENV NODE_VERSION 0.10.48 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && export CFLAGS="-D__USE_MISC" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.5-nodejs-0.10.x.dockerfile000066400000000000000000000032311320534473100336550ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-0.10.xFROM alpine:3.5 ENV NODE_VERSION 0.10.48 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && export CFLAGS="-D__USE_MISC" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.6-nodejs-0.10.x.dockerfile000066400000000000000000000032311320534473100336560ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-0.10.xFROM alpine:3.6 ENV NODE_VERSION 0.10.48 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && export CFLAGS="-D__USE_MISC" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-8.x/000077500000000000000000000000001320534473100245405ustar00rootroot00000000000000alpinelinux-3.2-nodejs-8.x.dockerfile000066400000000000000000000032021320534473100332320ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-8.xFROM alpine:3.2 ENV NODE_VERSION 8.8.1 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ tar xz \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.3-nodejs-8.x.dockerfile000066400000000000000000000032021320534473100332330ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-8.xFROM alpine:3.3 ENV NODE_VERSION 8.8.1 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ tar xz \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.4-nodejs-8.x.dockerfile000066400000000000000000000031611320534473100332400ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-8.xFROM alpine:3.4 ENV NODE_VERSION 8.8.1 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.5-nodejs-8.x.dockerfile000066400000000000000000000031611320534473100332410ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-8.xFROM alpine:3.5 ENV NODE_VERSION 8.8.1 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt alpinelinux-3.6-nodejs-8.x.dockerfile000066400000000000000000000031611320534473100332420ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/alpinelinux/nodejs-8.xFROM alpine:3.6 ENV NODE_VERSION 8.8.1 RUN addgroup -g 1000 node \ && adduser -u 1000 -G node -s /bin/sh -D node \ && apk add --no-cache \ libstdc++ \ && apk add --no-cache --virtual .build-deps \ binutils-gold \ curl \ g++ \ gcc \ gnupg \ libgcc \ linux-headers \ make \ python \ # gpg keys listed at https://github.com/nodejs/node#release-team && for key in \ 94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \ FD3A5288F042B6850C66B31F09FE44734EB7990E \ 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \ DD8F2338BAE7501E3DD5AC78C273792F7D83545D \ C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ B9AE9905FFD7803F25714661B63B535A4C206CA9 \ 56730D5401028683275BD23C23EFEFE93C4CFFFE \ ; do \ gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ gpg --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" ; \ done \ && curl -SLO "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ && curl -SLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ && grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ && tar -xf "node-v$NODE_VERSION.tar.xz" \ && cd "node-v$NODE_VERSION" \ && ./configure \ && make -j$(getconf _NPROCESSORS_ONLN) \ && make install \ && apk del .build-deps \ && cd .. \ && rm -Rf "node-v$NODE_VERSION" \ && rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt detect-libc-1.0.3/tests/integration/spec/amazonlinux/000077500000000000000000000000001320534473100226605ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-0.10.x/000077500000000000000000000000001320534473100247645ustar00rootroot00000000000000amazonlinux-2016.09-nodejs-0.10.x.dockerfile000066400000000000000000000001521320534473100342200ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-0.10.xFROM amazonlinux:2016.09 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs amazonlinux-2017.03-nodejs-0.10.x.dockerfile000066400000000000000000000001521320534473100342130ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-0.10.xFROM amazonlinux:2017.03 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs amazonlinux-2017.09-nodejs-0.10.x.dockerfile000066400000000000000000000001521320534473100342210ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-0.10.xFROM amazonlinux:2017.09 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-8.x/000077500000000000000000000000001320534473100245555ustar00rootroot00000000000000amazonlinux-2016.09-nodejs-8.x.dockerfile000066400000000000000000000001761320534473100336100ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-8.xFROM amazonlinux:2016.09 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs amazonlinux-2017.03-nodejs-8.x.dockerfile000066400000000000000000000001761320534473100336030ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-8.xFROM amazonlinux:2017.03 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs amazonlinux-2017.09-nodejs-8.x.dockerfile000066400000000000000000000001761320534473100336110ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/amazonlinux/nodejs-8.xFROM amazonlinux:2017.09 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/000077500000000000000000000000001320534473100216065ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/000077500000000000000000000000001320534473100237125ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-6.6-nodejs-0.10.x.dockerfile000066400000000000000000000001411320534473100316430ustar00rootroot00000000000000FROM centos:6.6 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-6.7-nodejs-0.10.x.dockerfile000066400000000000000000000001411320534473100316440ustar00rootroot00000000000000FROM centos:6.7 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-6.8-nodejs-0.10.x.dockerfile000066400000000000000000000001411320534473100316450ustar00rootroot00000000000000FROM centos:6.8 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-6.9-nodejs-0.10.x.dockerfile000066400000000000000000000001411320534473100316460ustar00rootroot00000000000000FROM centos:6.9 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-7.0-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100316430ustar00rootroot00000000000000FROM centos:7.0.1406 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-7.1-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100316440ustar00rootroot00000000000000FROM centos:7.1.1503 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-7.2-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100316450ustar00rootroot00000000000000FROM centos:7.2.1511 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-7.3-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100316460ustar00rootroot00000000000000FROM centos:7.3.1611 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-0.10.x/centos-7.4-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100316470ustar00rootroot00000000000000FROM centos:7.4.1708 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/000077500000000000000000000000001320534473100235035ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-6.6-nodejs-8.x.dockerfile000066400000000000000000000001651320534473100312330ustar00rootroot00000000000000FROM centos:6.6 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-6.7-nodejs-8.x.dockerfile000066400000000000000000000001651320534473100312340ustar00rootroot00000000000000FROM centos:6.7 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-6.8-nodejs-8.x.dockerfile000066400000000000000000000001651320534473100312350ustar00rootroot00000000000000FROM centos:6.8 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-6.9-nodejs-8.x.dockerfile000066400000000000000000000001651320534473100312360ustar00rootroot00000000000000FROM centos:6.9 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-7.0-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100312240ustar00rootroot00000000000000FROM centos:7.0.1406 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-7.1-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100312250ustar00rootroot00000000000000FROM centos:7.1.1503 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-7.2-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100312260ustar00rootroot00000000000000FROM centos:7.2.1511 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-7.3-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100312270ustar00rootroot00000000000000FROM centos:7.3.1611 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/centos/nodejs-8.x/centos-7.4-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100312300ustar00rootroot00000000000000FROM centos:7.4.1708 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/debian/000077500000000000000000000000001320534473100215355ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/debian/nodejs-0.10.x/000077500000000000000000000000001320534473100236415ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/debian/nodejs-0.10.x/debian-jessie-nodejs-0.10.x.dockerfile000066400000000000000000000002411320534473100324730ustar00rootroot00000000000000FROM debian:jessie RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_0.10 | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/debian/nodejs-0.10.x/debian-wheezy-nodejs-0.10.x.dockerfile000066400000000000000000000002411320534473100325240ustar00rootroot00000000000000FROM debian:wheezy RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_0.10 | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/debian/nodejs-8.x/000077500000000000000000000000001320534473100234325ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/debian/nodejs-8.x/debian-jessie-nodejs-8.x.dockerfile000066400000000000000000000002401320534473100320540ustar00rootroot00000000000000FROM debian:jessie RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/debian/nodejs-8.x/debian-stretch-nodejs-8.x.dockerfile000066400000000000000000000002411320534473100322470ustar00rootroot00000000000000FROM debian:stretch RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/minimal/000077500000000000000000000000001320534473100217415ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/minimal/minimal-rmg-nodejs-8.x.dockerfile000066400000000000000000000011151320534473100300740ustar00rootroot00000000000000# Provided by https://github.com/rmg FROM node:8.8.1 RUN mkdir -p /rootfs RUN ldd /bin/sh \ /usr/local/bin/node \ /lib/x86_64-linux-gnu/libnss_files.so.* \ /lib/x86_64-linux-gnu/libnss_dns.so.* \ | grep -o -e '\/\(usr\|lib\)[^ :]\+' \ | sort -u | tee /rootfs.list \ && echo /bin/sh >> /rootfs.list # The use of 'tar | tar' here is a quick'n'dirty replacement for rsync without # adding any deps: rsync --files-from=/rootfs.list -L -pog / /rootfs/ RUN cat /rootfs.list | tar -T- -cphf- | tar -C /rootfs -xpf- # noop FROM scratch COPY --from=0 /rootfs/ / detect-libc-1.0.3/tests/integration/spec/opensuse/000077500000000000000000000000001320534473100221545ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/opensuse/opensuse-42.2-nodejs-4.x.dockerfile000066400000000000000000000001001320534473100303070ustar00rootroot00000000000000FROM opensuse:42.2 RUN zypper --non-interactive install nodejs4 detect-libc-1.0.3/tests/integration/spec/opensuse/opensuse-42.3-nodejs-4.x.dockerfile000066400000000000000000000001001320534473100303100ustar00rootroot00000000000000FROM opensuse:42.3 RUN zypper --non-interactive install nodejs4 detect-libc-1.0.3/tests/integration/spec/opensuse/opensuse-tumbleweed-nodejs-4.x.dockerfile000066400000000000000000000001061320534473100320650ustar00rootroot00000000000000FROM opensuse:tumbleweed RUN zypper --non-interactive install nodejs4 detect-libc-1.0.3/tests/integration/spec/oraclelinux/000077500000000000000000000000001320534473100226405ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.x/000077500000000000000000000000001320534473100247445ustar00rootroot00000000000000oraclelinux-6.6-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336550ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:6.6 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-6.7-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336560ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:6.7 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-6.8-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336570ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:6.8 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-6.9-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336600ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:6.9 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-7.0-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336500ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:7.0 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-7.1-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336510ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:7.1 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-7.2-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336520ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:7.2 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-7.3-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336530ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:7.3 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs oraclelinux-7.4-nodejs-0.10.x.dockerfile000066400000000000000000000001461320534473100336540ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-0.10.xFROM oraclelinux:7.4 RUN curl -sL https://rpm.nodesource.com/setup | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.x/000077500000000000000000000000001320534473100245355ustar00rootroot00000000000000oraclelinux-6.6-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332360ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:6.6 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-6.7-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332370ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:6.7 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-6.8-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332400ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:6.8 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-6.9-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332410ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:6.9 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-7.0-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332310ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:7.0 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-7.1-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332320ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:7.1 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-7.2-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332330ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:7.2 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-7.3-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332340ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:7.3 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs oraclelinux-7.4-nodejs-8.x.dockerfile000066400000000000000000000001721320534473100332350ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/oraclelinux/nodejs-8.xFROM oraclelinux:7.4 RUN curl --silent --location https://rpm.nodesource.com/setup_8.x | bash - RUN yum -y install nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/000077500000000000000000000000001320534473100216355ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-0.10.x/000077500000000000000000000000001320534473100237415ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-0.10.x/ubuntu-14.04-nodejs-0.10.x.dockerfile000066400000000000000000000002401320534473100320560ustar00rootroot00000000000000FROM ubuntu:14.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_0.10 | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-0.10.x/ubuntu-16.04-nodejs-0.10.x.dockerfile000066400000000000000000000002751320534473100320700ustar00rootroot00000000000000FROM ubuntu:16.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_0.10 | bash - RUN apt-get install -y nodejs=0.10.48-1nodesource1~xenial1 detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-8.x/000077500000000000000000000000001320534473100235325ustar00rootroot00000000000000detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-8.x/ubuntu-14.04-nodejs-8.x.dockerfile000066400000000000000000000002371320534473100314460ustar00rootroot00000000000000FROM ubuntu:14.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-8.x/ubuntu-16.04-nodejs-8.x.dockerfile000066400000000000000000000002371320534473100314500ustar00rootroot00000000000000FROM ubuntu:16.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-8.x/ubuntu-17.04-nodejs-8.x.dockerfile000066400000000000000000000002371320534473100314510ustar00rootroot00000000000000FROM ubuntu:17.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/nodejs-8.x/ubuntu-17.10-nodejs-8.x.dockerfile000066400000000000000000000002371320534473100314460ustar00rootroot00000000000000FROM ubuntu:17.10 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/ubuntu-16.04-nodejs-0.12.x.dockerfile000066400000000000000000000002751320534473100277660ustar00rootroot00000000000000FROM ubuntu:16.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_0.12 | bash - RUN apt-get install -y nodejs=0.12.18-1nodesource1~xenial1 detect-libc-1.0.3/tests/integration/spec/ubuntu/ubuntu-16.04-nodejs-4.x.dockerfile000066400000000000000000000002371320534473100275470ustar00rootroot00000000000000FROM ubuntu:16.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_4.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/spec/ubuntu/ubuntu-16.04-nodejs-6.x.dockerfile000066400000000000000000000002371320534473100275510ustar00rootroot00000000000000FROM ubuntu:16.04 RUN apt-get update && apt-get install -y curl gnupg RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - RUN apt-get install -y nodejs detect-libc-1.0.3/tests/integration/test.py000077500000000000000000000274651320534473100207330ustar00rootroot00000000000000#!/usr/bin/env python2 import os import json import argparse import subprocess import threading import sys import tempfile from prettytable import PrettyTable # helper for progress output class RepeatingTimer(threading._Timer): def run(self): while True: self.finished.wait(self.interval) if self.finished.is_set(): return else: self.function(*self.args, **self.kwargs) def print_progress(): def output(): sys.stdout.write('.') sys.stdout.flush() sys.stdout.write('Waiting...') sys.stdout.flush() progress = RepeatingTimer(5.0, output) progress.daemon = True progress.start() def cancel(): progress.cancel() print '. done!' return cancel def execute_command(args, printwait=True, printout=True, raiseerr=True): # begin printing of progress stop_print_progress = lambda: None if printwait: stop_print_progress = print_progress() # ecexute command while collecting output with tempfile.TemporaryFile() as output: exitcode = subprocess.call(args, stdout=output, stderr=output) # stop printing of progress stop_print_progress() # collect process output output.seek(0) output_string = output.read() # print process output if printout: print output_string.strip() # raise exception of process failed if raiseerr and exitcode != 0: raise Exception('command execution failed', exitcode, args, output_string) # return output to caller return exitcode, output_string # sort helper def multikeysort(items, columns): from operator import itemgetter comparers = [((itemgetter(col[1:].strip()), -1) if col.startswith('-') else (itemgetter(col.strip()), 1)) for col in columns] def comparer(left, right): for fn, mult in comparers: result = cmp(fn(left), fn(right)) if result: return mult * result else: return 0 return sorted(items, cmp=comparer) # get script directory scriptdir = os.path.dirname(__file__) projectdir = os.path.abspath(os.path.join(scriptdir, '..', '..')) # load configuration config = None with open(os.path.join(scriptdir, 'config.json')) as config_file: config = json.load(config_file) # load specification spec = None with open(os.path.join(scriptdir, 'spec.json')) as spec_file: spec = json.load(spec_file) # UTIL: list all defined matrics def list_matrices(): return spec.keys() # UTIL: get matrix (exploded) def get_matrix(matrix): data = spec[matrix] matrix_dec = matrix.split(':', 2) result = [] for distver in data['dist']: for nodever in data['node']: item = { 'matrix': matrix, 'dist.code': matrix_dec[0], 'dist.version': distver, 'node.version': nodever, 'expected': { } } def extract_vars(conf): for varkey in conf: if varkey.startswith('$'): item['expected'][varkey[1:]] = conf[varkey] extract_vars(data) extract_vars(data['dist'][distver]) extract_vars(data['node'][nodever]) result.append(item) return multikeysort(result, ['dist.code', 'dist.version', 'node.version']) # UTIL: get matrices (exploded) def get_matrices(matrices): result = [] for matrix in matrices: result += get_matrix(matrix) return multikeysort(result, ['dist.code', 'dist.version', 'node.version']) # UTIL: find corresponding dockerfile def get_dockerfile(distname, distver, nodever): dockerfile = distname + '-' + distver + '-' + 'nodejs' + '-' + nodever + '.dockerfile' for rootdir, dirnames, filenames in os.walk(os.path.join(scriptdir, 'spec', distname)): for filename in filenames: if filename == dockerfile: return os.path.join(rootdir, filename) return None # COMMAND: list all tags def cmd_list(matrices): items = get_matrices(matrices) for item in items: tag = item['dist.code'] + '-' + item['dist.version'] + '-' + 'nodejs' + '-' + item['node.version'] print(tag + ' (' + item['matrix'] + ')') # COMMAND: build docker images def cmd_build(matrices): items = get_matrices(matrices) failed = False for item in items: tag = item['dist.code'] + '-' + item['dist.version'] + '-' + 'nodejs' + '-' + item['node.version'] print 'Building: ' + tag dockerfile = get_dockerfile(item['dist.code'], item['dist.version'], item['node.version']) if dockerfile is not None: exitcode, output = execute_command([ 'docker', 'build', '--quiet', '-t', config['registry'] + ':' + tag, '-f', dockerfile, os.path.join(scriptdir, 'spec', item['dist.code']) ], raiseerr=False) if exitcode != 0: failed = True print "... failed!" else: failed = True print "... dockerfile not found!" if failed: print "At least one item failed!" sys.exit(1) print 'All done!' # COMMAND: push docker images def cmd_push(matrices): items = get_matrices(matrices) failed = False for item in items: tag = item['dist.code'] + '-' + item['dist.version'] + '-' + 'nodejs' + '-' + item['node.version'] print 'Pushing: ' + tag exitcode, output = execute_command([ 'docker', 'push', config['registry'] + ':' + tag ], raiseerr=False) if exitcode != 0: failed = True print "... failed!" if failed: print "At least one item failed!" sys.exit(1) print 'All done!' # COMMAND: pull docker images def cmd_pull(matrices): items = get_matrices(matrices) failed = False for item in items: tag = item['dist.code'] + '-' + item['dist.version'] + '-' + 'nodejs' + '-' + item['node.version'] print 'Pulling: ' + tag exitcode, output = execute_command([ 'docker', 'pull', config['registry'] + ':' + tag ], raiseerr=False) if exitcode != 0: failed = True print "... failed!" if failed: print "At least one item failed!" sys.exit(1) print 'All done!' # COMMAND: run integration tests def cmd_run(matrices): # run tests items = get_matrices(matrices) for item in items: tag = item['dist.code'] + '-' + item['dist.version'] + '-' + 'nodejs' + '-' + item['node.version'] print 'Testing: ' + tag # run test command exitcode, output = execute_command( [ 'docker', 'run', '--rm', '-v', projectdir + ':/module', config['registry'] + ':' + tag, 'sh', '-c', 'cd /module && node ./tests/integration/probe.js' ], printwait=False, raiseerr=False ) # extract result item['actual'] = None if exitcode != 0: print "... test not executed!" else: for line in output.split('\n'): if line.startswith('result='): try: item['actual'] = json.loads(line[7:]) print "... result found!" except ValueError: print "... result not found!" print "... test executed!" # validate check_executed = item['actual'] is not None item['check'] = { 'executed': check_executed, 'summary': check_executed } for check in item['expected']: if check_executed and check in item['actual']: item['check'][check] = (item['expected'][check] == item['actual'][check]) else: item['check'][check] = False if not item['check'][check]: item['check']['summary'] = False if check_executed and check in item['actual']: print '... check "' + check + '" did not pass; expected "' + item['expected'][check] + '" vs. "' + item['actual'][check] + '"!' else: print '... check "' + check + '" not executed; expected "' + item['expected'][check] + '"!' print 'All done!' # generate counts counts = { 'total': { }, 'ok': { }, 'failed': { } } for item in items: for check in item['check']: if check not in counts['total']: counts['total'][check] = 0 if check not in counts['ok']: counts['ok'][check] = 0 if check not in counts['failed']: counts['failed'][check] = 0 counts['total'][check] += 1 if item['check'][check]: counts['ok'][check] += 1 else: counts['failed'][check] += 1 # print result print "Result:" table = PrettyTable(['Configuration', 'Executed', 'Method', 'Family', 'Version', 'Node.js', 'Distribution', 'Summary']) table.align = 'l' for item in items: tag = item['dist.code'] + '-' + item['dist.version'] + '-' + 'nodejs' + '-' + item['node.version'] table.add_row([ tag, 'OK' if item['check']['executed'] else 'FAILED', 'OK' if item['check']['detect.method'] else 'FAILED', 'OK' if item['check']['libc.family'] else 'FAILED', 'OK' if item['check']['libc.version'] else 'FAILED', 'OK' if item['check']['node.version'] else 'FAILED', 'OK' if item['check']['dist.name'] else 'FAILED', 'OK' if item['check']['summary'] else 'FAILED' ]) print(table) # print counts table = PrettyTable(['Configuration', 'Executed', 'Method', 'Family', 'Version', 'Node.js', 'Distribution', 'Summary']) table.align = 'l' table.add_row([ 'TOTAL', counts['total']['executed'], counts['total']['detect.method'], counts['total']['libc.family'], counts['total']['libc.version'], counts['total']['node.version'], counts['total']['dist.name'], counts['total']['summary'] ]) table.add_row([ 'OK', counts['ok']['executed'], counts['ok']['detect.method'], counts['ok']['libc.family'], counts['ok']['libc.version'], counts['ok']['node.version'], counts['ok']['dist.name'], counts['ok']['summary'] ]) table.add_row([ 'FAILED', counts['failed']['executed'], counts['failed']['detect.method'], counts['failed']['libc.family'], counts['failed']['libc.version'], counts['failed']['node.version'], counts['failed']['dist.name'], counts['failed']['summary'] ]) print(table) # handle exit code if counts['failed']['summary'] > 0: sys.exit(1) # run main routine if __name__ == "__main__": # parse arguments parser = argparse.ArgumentParser(description='prepare and execute docker based integration tests.') parser.add_argument('command', choices=['list', 'build', 'push', 'pull', 'run'], help='command to be executed') parser.add_argument('matrix', nargs='*', help='matrix filter (default = all)') args = parser.parse_args() # validate selected matrices matrices = None if args.matrix is None or len(args.matrix) == 0: matrices = list_matrices() else: matrices = [] for arg_matrix in args.matrix: for matrix in list_matrices(): if arg_matrix == matrix or matrix.startswith(arg_matrix+':'): matrices.append(matrix) # run command cmds = { 'list': cmd_list, 'build': cmd_build, 'push': cmd_push, 'pull': cmd_pull, 'run': cmd_run } cmds[args.command](matrices)