├── .gitallowed ├── .github ├── ISSUE_TEMPLATE.md ├── PULL_REQUEST_TEMPLATE.md └── workflows │ ├── build.yml │ └── gitsecrets.yml ├── .gitignore ├── .travis.yml ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── Makefile ├── NOTICE ├── README.md ├── THIRD-PARTY ├── ecs-init ├── ECSVERSION ├── Gopkg.lock ├── Gopkg.toml ├── backoff │ ├── backoff.go │ └── backoff_test.go ├── cache │ ├── cache.go │ ├── cache_test.go │ ├── dependencies.go │ └── dependencies_mocks.go ├── cmd │ └── cmd.go ├── config │ ├── common.go │ ├── common_test.go │ ├── config_al2.go │ ├── config_generic_rpm.go │ ├── config_suse_ubuntu_debian.go │ ├── config_unspecified.go │ ├── development.go │ ├── logger.go │ └── release.go ├── docker │ ├── backoff_mocks.go │ ├── dependencies.go │ ├── dependencies_mocks.go │ ├── dependencies_test.go │ ├── docker.go │ ├── docker_config.go │ └── docker_test.go ├── ecs-init.go ├── engine │ ├── dependencies.go │ ├── dependencies_mocks.go │ ├── engine.go │ └── engine_test.go ├── exec │ ├── exec.go │ ├── iptables │ │ ├── cmd_mocks.go │ │ ├── exec_mocks.go │ │ ├── iptables.go │ │ └── iptables_test.go │ └── sysctl │ │ ├── cmd_mocks.go │ │ ├── exec_mocks.go │ │ ├── sysctl.go │ │ └── sysctl_test.go ├── gpu │ ├── nvidia_gpu_manager.go │ ├── nvidia_gpu_manager_mocks.go │ └── nvidia_gpu_manager_test.go ├── vendor │ ├── github.com │ │ ├── Azure │ │ │ └── go-ansiterm │ │ │ │ ├── LICENSE │ │ │ │ ├── README.md │ │ │ │ ├── constants.go │ │ │ │ ├── context.go │ │ │ │ ├── csi_entry_state.go │ │ │ │ ├── csi_param_state.go │ │ │ │ ├── escape_intermediate_state.go │ │ │ │ ├── escape_state.go │ │ │ │ ├── event_handler.go │ │ │ │ ├── ground_state.go │ │ │ │ ├── osc_string_state.go │ │ │ │ ├── parser.go │ │ │ │ ├── parser_action_helpers.go │ │ │ │ ├── parser_actions.go │ │ │ │ ├── states.go │ │ │ │ ├── utilities.go │ │ │ │ └── winterm │ │ │ │ ├── ansi.go │ │ │ │ ├── api.go │ │ │ │ ├── attr_translation.go │ │ │ │ ├── cursor_helpers.go │ │ │ │ ├── erase_helpers.go │ │ │ │ ├── scroll_helper.go │ │ │ │ ├── utilities.go │ │ │ │ └── win_event_handler.go │ │ ├── Microsoft │ │ │ └── go-winio │ │ │ │ ├── .gitignore │ │ │ │ ├── LICENSE │ │ │ │ ├── README.md │ │ │ │ ├── archive │ │ │ │ └── tar │ │ │ │ │ └── LICENSE │ │ │ │ ├── backup.go │ │ │ │ ├── file.go │ │ │ │ ├── fileinfo.go │ │ │ │ ├── pipe.go │ │ │ │ ├── privilege.go │ │ │ │ ├── reparse.go │ │ │ │ ├── sd.go │ │ │ │ ├── syscall.go │ │ │ │ └── zsyscall_windows.go │ │ ├── NVIDIA │ │ │ └── gpu-monitoring-tools │ │ │ │ ├── LICENSE │ │ │ │ └── bindings │ │ │ │ └── go │ │ │ │ └── nvml │ │ │ │ ├── bindings.go │ │ │ │ ├── nvml.go │ │ │ │ ├── nvml.h │ │ │ │ ├── nvml_dl.c │ │ │ │ └── nvml_dl.h │ │ ├── Nvveen │ │ │ └── Gotty │ │ │ │ ├── LICENSE │ │ │ │ ├── README │ │ │ │ ├── TODO │ │ │ │ ├── attributes.go │ │ │ │ ├── gotty.go │ │ │ │ ├── parser.go │ │ │ │ └── types.go │ │ ├── Sirupsen │ │ │ └── logrus │ │ │ │ ├── .gitignore │ │ │ │ ├── .travis.yml │ │ │ │ ├── CHANGELOG.md │ │ │ │ ├── LICENSE │ │ │ │ ├── README.md │ │ │ │ ├── alt_exit.go │ │ │ │ ├── doc.go │ │ │ │ ├── entry.go │ │ │ │ ├── exported.go │ │ │ │ ├── formatter.go │ │ │ │ ├── hooks.go │ │ │ │ ├── json_formatter.go │ │ │ │ ├── logger.go │ │ │ │ ├── logrus.go │ │ │ │ ├── terminal_appengine.go │ │ │ │ ├── terminal_bsd.go │ │ │ │ ├── terminal_linux.go │ │ │ │ ├── terminal_notwindows.go │ │ │ │ ├── terminal_solaris.go │ │ │ │ ├── terminal_windows.go │ │ │ │ ├── text_formatter.go │ │ │ │ └── writer.go │ │ ├── aws │ │ │ └── aws-sdk-go │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── NOTICE.txt │ │ │ │ ├── aws │ │ │ │ ├── arn │ │ │ │ │ └── arn.go │ │ │ │ ├── awserr │ │ │ │ │ ├── error.go │ │ │ │ │ └── types.go │ │ │ │ ├── awsutil │ │ │ │ │ ├── copy.go │ │ │ │ │ ├── equal.go │ │ │ │ │ ├── path_value.go │ │ │ │ │ ├── prettify.go │ │ │ │ │ └── string_value.go │ │ │ │ ├── client │ │ │ │ │ ├── client.go │ │ │ │ │ ├── default_retryer.go │ │ │ │ │ ├── logger.go │ │ │ │ │ ├── metadata │ │ │ │ │ │ └── client_info.go │ │ │ │ │ └── no_op_retryer.go │ │ │ │ ├── config.go │ │ │ │ ├── context_1_5.go │ │ │ │ ├── context_1_9.go │ │ │ │ ├── context_background_1_5.go │ │ │ │ ├── context_background_1_7.go │ │ │ │ ├── context_sleep.go │ │ │ │ ├── convert_types.go │ │ │ │ ├── corehandlers │ │ │ │ │ ├── handlers.go │ │ │ │ │ ├── param_validator.go │ │ │ │ │ └── user_agent.go │ │ │ │ ├── credentials │ │ │ │ │ ├── chain_provider.go │ │ │ │ │ ├── context_background_go1.5.go │ │ │ │ │ ├── context_background_go1.7.go │ │ │ │ │ ├── context_go1.5.go │ │ │ │ │ ├── context_go1.9.go │ │ │ │ │ ├── credentials.go │ │ │ │ │ ├── ec2rolecreds │ │ │ │ │ │ └── ec2_role_provider.go │ │ │ │ │ ├── endpointcreds │ │ │ │ │ │ └── provider.go │ │ │ │ │ ├── env_provider.go │ │ │ │ │ ├── example.ini │ │ │ │ │ ├── processcreds │ │ │ │ │ │ └── provider.go │ │ │ │ │ ├── shared_credentials_provider.go │ │ │ │ │ ├── static_provider.go │ │ │ │ │ └── stscreds │ │ │ │ │ │ ├── assume_role_provider.go │ │ │ │ │ │ └── web_identity_provider.go │ │ │ │ ├── csm │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── enable.go │ │ │ │ │ ├── metric.go │ │ │ │ │ ├── metric_chan.go │ │ │ │ │ ├── metric_exception.go │ │ │ │ │ └── reporter.go │ │ │ │ ├── defaults │ │ │ │ │ ├── defaults.go │ │ │ │ │ └── shared_config.go │ │ │ │ ├── doc.go │ │ │ │ ├── ec2metadata │ │ │ │ │ ├── api.go │ │ │ │ │ ├── service.go │ │ │ │ │ └── token_provider.go │ │ │ │ ├── endpoints │ │ │ │ │ ├── decode.go │ │ │ │ │ ├── defaults.go │ │ │ │ │ ├── dep_service_ids.go │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── endpoints.go │ │ │ │ │ ├── legacy_regions.go │ │ │ │ │ ├── v3model.go │ │ │ │ │ └── v3model_codegen.go │ │ │ │ ├── errors.go │ │ │ │ ├── jsonvalue.go │ │ │ │ ├── logger.go │ │ │ │ ├── request │ │ │ │ │ ├── connection_reset_error.go │ │ │ │ │ ├── handlers.go │ │ │ │ │ ├── http_request.go │ │ │ │ │ ├── offset_reader.go │ │ │ │ │ ├── request.go │ │ │ │ │ ├── request_1_7.go │ │ │ │ │ ├── request_1_8.go │ │ │ │ │ ├── request_context.go │ │ │ │ │ ├── request_context_1_6.go │ │ │ │ │ ├── request_pagination.go │ │ │ │ │ ├── retryer.go │ │ │ │ │ ├── timeout_read_closer.go │ │ │ │ │ ├── validation.go │ │ │ │ │ └── waiter.go │ │ │ │ ├── session │ │ │ │ │ ├── cabundle_transport.go │ │ │ │ │ ├── cabundle_transport_1_5.go │ │ │ │ │ ├── cabundle_transport_1_6.go │ │ │ │ │ ├── credentials.go │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── env_config.go │ │ │ │ │ ├── session.go │ │ │ │ │ └── shared_config.go │ │ │ │ ├── signer │ │ │ │ │ └── v4 │ │ │ │ │ │ ├── header_rules.go │ │ │ │ │ │ ├── options.go │ │ │ │ │ │ ├── request_context_go1.5.go │ │ │ │ │ │ ├── request_context_go1.7.go │ │ │ │ │ │ ├── stream.go │ │ │ │ │ │ ├── uri_path.go │ │ │ │ │ │ └── v4.go │ │ │ │ ├── types.go │ │ │ │ ├── url.go │ │ │ │ ├── url_1_7.go │ │ │ │ └── version.go │ │ │ │ ├── internal │ │ │ │ ├── context │ │ │ │ │ └── background_go1.5.go │ │ │ │ ├── ini │ │ │ │ │ ├── ast.go │ │ │ │ │ ├── comma_token.go │ │ │ │ │ ├── comment_token.go │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── empty_token.go │ │ │ │ │ ├── expression.go │ │ │ │ │ ├── fuzz.go │ │ │ │ │ ├── ini.go │ │ │ │ │ ├── ini_lexer.go │ │ │ │ │ ├── ini_parser.go │ │ │ │ │ ├── literal_tokens.go │ │ │ │ │ ├── newline_token.go │ │ │ │ │ ├── number_helper.go │ │ │ │ │ ├── op_tokens.go │ │ │ │ │ ├── parse_error.go │ │ │ │ │ ├── parse_stack.go │ │ │ │ │ ├── sep_tokens.go │ │ │ │ │ ├── skipper.go │ │ │ │ │ ├── statement.go │ │ │ │ │ ├── value_util.go │ │ │ │ │ ├── visitor.go │ │ │ │ │ ├── walker.go │ │ │ │ │ └── ws_token.go │ │ │ │ ├── s3shared │ │ │ │ │ ├── arn │ │ │ │ │ │ ├── accesspoint_arn.go │ │ │ │ │ │ ├── arn.go │ │ │ │ │ │ └── outpost_arn.go │ │ │ │ │ ├── endpoint_errors.go │ │ │ │ │ ├── resource_request.go │ │ │ │ │ └── s3err │ │ │ │ │ │ └── error.go │ │ │ │ ├── sdkio │ │ │ │ │ ├── byte.go │ │ │ │ │ ├── io_go1.6.go │ │ │ │ │ └── io_go1.7.go │ │ │ │ ├── sdkmath │ │ │ │ │ ├── floor.go │ │ │ │ │ └── floor_go1.9.go │ │ │ │ ├── sdkrand │ │ │ │ │ ├── locked_source.go │ │ │ │ │ ├── read.go │ │ │ │ │ └── read_1_5.go │ │ │ │ ├── sdkuri │ │ │ │ │ └── path.go │ │ │ │ ├── shareddefaults │ │ │ │ │ ├── ecs_container.go │ │ │ │ │ └── shared_config.go │ │ │ │ ├── strings │ │ │ │ │ └── strings.go │ │ │ │ └── sync │ │ │ │ │ └── singleflight │ │ │ │ │ ├── LICENSE │ │ │ │ │ └── singleflight.go │ │ │ │ ├── private │ │ │ │ ├── checksum │ │ │ │ │ └── content_md5.go │ │ │ │ └── protocol │ │ │ │ │ ├── eventstream │ │ │ │ │ ├── debug.go │ │ │ │ │ ├── decode.go │ │ │ │ │ ├── encode.go │ │ │ │ │ ├── error.go │ │ │ │ │ ├── eventstreamapi │ │ │ │ │ │ ├── error.go │ │ │ │ │ │ ├── reader.go │ │ │ │ │ │ ├── shared.go │ │ │ │ │ │ ├── signer.go │ │ │ │ │ │ ├── stream_writer.go │ │ │ │ │ │ └── writer.go │ │ │ │ │ ├── header.go │ │ │ │ │ ├── header_value.go │ │ │ │ │ └── message.go │ │ │ │ │ ├── host.go │ │ │ │ │ ├── host_prefix.go │ │ │ │ │ ├── idempotency.go │ │ │ │ │ ├── json │ │ │ │ │ └── jsonutil │ │ │ │ │ │ ├── build.go │ │ │ │ │ │ └── unmarshal.go │ │ │ │ │ ├── jsonvalue.go │ │ │ │ │ ├── payload.go │ │ │ │ │ ├── protocol.go │ │ │ │ │ ├── query │ │ │ │ │ ├── build.go │ │ │ │ │ ├── queryutil │ │ │ │ │ │ └── queryutil.go │ │ │ │ │ ├── unmarshal.go │ │ │ │ │ └── unmarshal_error.go │ │ │ │ │ ├── rest │ │ │ │ │ ├── build.go │ │ │ │ │ ├── payload.go │ │ │ │ │ └── unmarshal.go │ │ │ │ │ ├── restxml │ │ │ │ │ └── restxml.go │ │ │ │ │ ├── timestamp.go │ │ │ │ │ ├── unmarshal.go │ │ │ │ │ ├── unmarshal_error.go │ │ │ │ │ └── xml │ │ │ │ │ └── xmlutil │ │ │ │ │ ├── build.go │ │ │ │ │ ├── sort.go │ │ │ │ │ ├── unmarshal.go │ │ │ │ │ └── xml_to_struct.go │ │ │ │ └── service │ │ │ │ ├── s3 │ │ │ │ ├── api.go │ │ │ │ ├── body_hash.go │ │ │ │ ├── bucket_location.go │ │ │ │ ├── customizations.go │ │ │ │ ├── doc.go │ │ │ │ ├── doc_custom.go │ │ │ │ ├── endpoint.go │ │ │ │ ├── endpoint_builder.go │ │ │ │ ├── errors.go │ │ │ │ ├── host_style_bucket.go │ │ │ │ ├── platform_handlers.go │ │ │ │ ├── platform_handlers_go1.6.go │ │ │ │ ├── s3iface │ │ │ │ │ └── interface.go │ │ │ │ ├── s3manager │ │ │ │ │ ├── batch.go │ │ │ │ │ ├── bucket_region.go │ │ │ │ │ ├── buffered_read_seeker.go │ │ │ │ │ ├── default_read_seeker_write_to.go │ │ │ │ │ ├── default_read_seeker_write_to_windows.go │ │ │ │ │ ├── default_writer_read_from.go │ │ │ │ │ ├── default_writer_read_from_windows.go │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── download.go │ │ │ │ │ ├── pool.go │ │ │ │ │ ├── read_seeker_write_to.go │ │ │ │ │ ├── upload.go │ │ │ │ │ ├── upload_input.go │ │ │ │ │ └── writer_read_from.go │ │ │ │ ├── service.go │ │ │ │ ├── sse.go │ │ │ │ ├── statusok_error.go │ │ │ │ ├── unmarshal_error.go │ │ │ │ └── waiters.go │ │ │ │ └── sts │ │ │ │ ├── api.go │ │ │ │ ├── customizations.go │ │ │ │ ├── doc.go │ │ │ │ ├── errors.go │ │ │ │ ├── service.go │ │ │ │ └── stsiface │ │ │ │ └── interface.go │ │ ├── cihub │ │ │ └── seelog │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── README.markdown │ │ │ │ ├── archive │ │ │ │ ├── archive.go │ │ │ │ ├── gzip │ │ │ │ │ └── gzip.go │ │ │ │ ├── tar │ │ │ │ │ └── tar.go │ │ │ │ └── zip │ │ │ │ │ └── zip.go │ │ │ │ ├── behavior_adaptivelogger.go │ │ │ │ ├── behavior_asynclogger.go │ │ │ │ ├── behavior_asynclooplogger.go │ │ │ │ ├── behavior_asynctimerlogger.go │ │ │ │ ├── behavior_synclogger.go │ │ │ │ ├── cfg_config.go │ │ │ │ ├── cfg_errors.go │ │ │ │ ├── cfg_logconfig.go │ │ │ │ ├── cfg_parser.go │ │ │ │ ├── common_closer.go │ │ │ │ ├── common_constraints.go │ │ │ │ ├── common_context.go │ │ │ │ ├── common_exception.go │ │ │ │ ├── common_flusher.go │ │ │ │ ├── common_loglevel.go │ │ │ │ ├── dispatch_custom.go │ │ │ │ ├── dispatch_dispatcher.go │ │ │ │ ├── dispatch_filterdispatcher.go │ │ │ │ ├── dispatch_splitdispatcher.go │ │ │ │ ├── doc.go │ │ │ │ ├── format.go │ │ │ │ ├── internals_baseerror.go │ │ │ │ ├── internals_fsutils.go │ │ │ │ ├── internals_xmlnode.go │ │ │ │ ├── log.go │ │ │ │ ├── logger.go │ │ │ │ ├── writers_bufferedwriter.go │ │ │ │ ├── writers_connwriter.go │ │ │ │ ├── writers_consolewriter.go │ │ │ │ ├── writers_filewriter.go │ │ │ │ ├── writers_formattedwriter.go │ │ │ │ ├── writers_rollingfilewriter.go │ │ │ │ └── writers_smtpwriter.go │ │ ├── coreos │ │ │ └── go-systemd │ │ │ │ ├── LICENSE │ │ │ │ ├── NOTICE │ │ │ │ └── activation │ │ │ │ ├── files.go │ │ │ │ ├── listeners.go │ │ │ │ └── packetconns.go │ │ ├── davecgh │ │ │ └── go-spew │ │ │ │ ├── LICENSE │ │ │ │ └── spew │ │ │ │ ├── bypass.go │ │ │ │ ├── bypasssafe.go │ │ │ │ ├── common.go │ │ │ │ ├── config.go │ │ │ │ ├── doc.go │ │ │ │ ├── dump.go │ │ │ │ ├── format.go │ │ │ │ └── spew.go │ │ ├── docker │ │ │ ├── docker │ │ │ │ ├── AUTHORS │ │ │ │ ├── LICENSE │ │ │ │ ├── NOTICE │ │ │ │ ├── api │ │ │ │ │ └── types │ │ │ │ │ │ ├── auth.go │ │ │ │ │ │ ├── blkiodev │ │ │ │ │ │ └── blkio.go │ │ │ │ │ │ ├── client.go │ │ │ │ │ │ ├── configs.go │ │ │ │ │ │ ├── container │ │ │ │ │ │ ├── config.go │ │ │ │ │ │ ├── container_changes.go │ │ │ │ │ │ ├── container_create.go │ │ │ │ │ │ ├── container_top.go │ │ │ │ │ │ ├── container_update.go │ │ │ │ │ │ ├── container_wait.go │ │ │ │ │ │ ├── host_config.go │ │ │ │ │ │ ├── hostconfig_unix.go │ │ │ │ │ │ ├── hostconfig_windows.go │ │ │ │ │ │ └── waitcondition.go │ │ │ │ │ │ ├── error_response.go │ │ │ │ │ │ ├── filters │ │ │ │ │ │ └── parse.go │ │ │ │ │ │ ├── graph_driver_data.go │ │ │ │ │ │ ├── id_response.go │ │ │ │ │ │ ├── image_delete_response_item.go │ │ │ │ │ │ ├── image_summary.go │ │ │ │ │ │ ├── mount │ │ │ │ │ │ └── mount.go │ │ │ │ │ │ ├── network │ │ │ │ │ │ └── network.go │ │ │ │ │ │ ├── plugin.go │ │ │ │ │ │ ├── plugin_device.go │ │ │ │ │ │ ├── plugin_env.go │ │ │ │ │ │ ├── plugin_interface_type.go │ │ │ │ │ │ ├── plugin_mount.go │ │ │ │ │ │ ├── plugin_responses.go │ │ │ │ │ │ ├── port.go │ │ │ │ │ │ ├── registry │ │ │ │ │ │ ├── authenticate.go │ │ │ │ │ │ └── registry.go │ │ │ │ │ │ ├── seccomp.go │ │ │ │ │ │ ├── service_update_response.go │ │ │ │ │ │ ├── stats.go │ │ │ │ │ │ ├── strslice │ │ │ │ │ │ └── strslice.go │ │ │ │ │ │ ├── swarm │ │ │ │ │ │ ├── common.go │ │ │ │ │ │ ├── config.go │ │ │ │ │ │ ├── container.go │ │ │ │ │ │ ├── network.go │ │ │ │ │ │ ├── node.go │ │ │ │ │ │ ├── runtime.go │ │ │ │ │ │ ├── secret.go │ │ │ │ │ │ ├── service.go │ │ │ │ │ │ ├── swarm.go │ │ │ │ │ │ └── task.go │ │ │ │ │ │ ├── types.go │ │ │ │ │ │ ├── versions │ │ │ │ │ │ ├── README.md │ │ │ │ │ │ └── compare.go │ │ │ │ │ │ └── volume.go │ │ │ │ ├── contrib │ │ │ │ │ ├── selinux-fedora-24 │ │ │ │ │ │ └── docker-engine-selinux │ │ │ │ │ │ │ └── LICENSE │ │ │ │ │ ├── selinux-oraclelinux-7 │ │ │ │ │ │ └── docker-engine-selinux │ │ │ │ │ │ │ └── LICENSE │ │ │ │ │ └── syntax │ │ │ │ │ │ └── vim │ │ │ │ │ │ └── LICENSE │ │ │ │ ├── docs │ │ │ │ │ └── static_files │ │ │ │ │ │ └── contributors.png │ │ │ │ ├── hack │ │ │ │ │ ├── generate-authors.sh │ │ │ │ │ └── make │ │ │ │ │ │ └── .build-deb │ │ │ │ │ │ ├── docker-engine.docker.default │ │ │ │ │ │ ├── docker-engine.docker.init │ │ │ │ │ │ ├── docker-engine.docker.upstart │ │ │ │ │ │ └── docker-engine.udev │ │ │ │ ├── opts │ │ │ │ │ ├── env.go │ │ │ │ │ ├── hosts.go │ │ │ │ │ ├── hosts_unix.go │ │ │ │ │ ├── hosts_windows.go │ │ │ │ │ ├── ip.go │ │ │ │ │ ├── opts.go │ │ │ │ │ ├── opts_unix.go │ │ │ │ │ ├── opts_windows.go │ │ │ │ │ ├── quotedstring.go │ │ │ │ │ ├── runtime.go │ │ │ │ │ └── ulimit.go │ │ │ │ ├── pkg │ │ │ │ │ ├── archive │ │ │ │ │ │ ├── README.md │ │ │ │ │ │ ├── archive.go │ │ │ │ │ │ ├── archive_linux.go │ │ │ │ │ │ ├── archive_other.go │ │ │ │ │ │ ├── archive_unix.go │ │ │ │ │ │ ├── archive_windows.go │ │ │ │ │ │ ├── changes.go │ │ │ │ │ │ ├── changes_linux.go │ │ │ │ │ │ ├── changes_other.go │ │ │ │ │ │ ├── changes_unix.go │ │ │ │ │ │ ├── changes_windows.go │ │ │ │ │ │ ├── copy.go │ │ │ │ │ │ ├── copy_unix.go │ │ │ │ │ │ ├── copy_windows.go │ │ │ │ │ │ ├── diff.go │ │ │ │ │ │ ├── example_changes.go │ │ │ │ │ │ ├── time_linux.go │ │ │ │ │ │ ├── time_unsupported.go │ │ │ │ │ │ ├── whiteouts.go │ │ │ │ │ │ └── wrap.go │ │ │ │ │ ├── fileutils │ │ │ │ │ │ ├── fileutils.go │ │ │ │ │ │ ├── fileutils_darwin.go │ │ │ │ │ │ ├── fileutils_solaris.go │ │ │ │ │ │ ├── fileutils_unix.go │ │ │ │ │ │ └── fileutils_windows.go │ │ │ │ │ ├── homedir │ │ │ │ │ │ ├── homedir.go │ │ │ │ │ │ ├── homedir_linux.go │ │ │ │ │ │ └── homedir_others.go │ │ │ │ │ ├── idtools │ │ │ │ │ │ ├── idtools.go │ │ │ │ │ │ ├── idtools_unix.go │ │ │ │ │ │ ├── idtools_windows.go │ │ │ │ │ │ ├── usergroupadd_linux.go │ │ │ │ │ │ ├── usergroupadd_unsupported.go │ │ │ │ │ │ └── utils_unix.go │ │ │ │ │ ├── ioutils │ │ │ │ │ │ ├── buffer.go │ │ │ │ │ │ ├── bytespipe.go │ │ │ │ │ │ ├── fswriters.go │ │ │ │ │ │ ├── multireader.go │ │ │ │ │ │ ├── readers.go │ │ │ │ │ │ ├── temp_unix.go │ │ │ │ │ │ ├── temp_windows.go │ │ │ │ │ │ ├── writeflusher.go │ │ │ │ │ │ └── writers.go │ │ │ │ │ ├── jsonlog │ │ │ │ │ │ ├── jsonlog.go │ │ │ │ │ │ ├── jsonlog_marshalling.go │ │ │ │ │ │ ├── jsonlogbytes.go │ │ │ │ │ │ └── time_marshalling.go │ │ │ │ │ ├── jsonmessage │ │ │ │ │ │ └── jsonmessage.go │ │ │ │ │ ├── longpath │ │ │ │ │ │ └── longpath.go │ │ │ │ │ ├── mount │ │ │ │ │ │ ├── flags.go │ │ │ │ │ │ ├── flags_freebsd.go │ │ │ │ │ │ ├── flags_linux.go │ │ │ │ │ │ ├── flags_unsupported.go │ │ │ │ │ │ ├── mount.go │ │ │ │ │ │ ├── mounter_freebsd.go │ │ │ │ │ │ ├── mounter_linux.go │ │ │ │ │ │ ├── mounter_solaris.go │ │ │ │ │ │ ├── mounter_unsupported.go │ │ │ │ │ │ ├── mountinfo.go │ │ │ │ │ │ ├── mountinfo_freebsd.go │ │ │ │ │ │ ├── mountinfo_linux.go │ │ │ │ │ │ ├── mountinfo_solaris.go │ │ │ │ │ │ ├── mountinfo_unsupported.go │ │ │ │ │ │ ├── mountinfo_windows.go │ │ │ │ │ │ ├── sharedsubtree_linux.go │ │ │ │ │ │ └── sharedsubtree_solaris.go │ │ │ │ │ ├── pools │ │ │ │ │ │ └── pools.go │ │ │ │ │ ├── promise │ │ │ │ │ │ └── promise.go │ │ │ │ │ ├── stdcopy │ │ │ │ │ │ └── stdcopy.go │ │ │ │ │ ├── symlink │ │ │ │ │ │ ├── LICENSE.APACHE │ │ │ │ │ │ └── LICENSE.BSD │ │ │ │ │ ├── system │ │ │ │ │ │ ├── chtimes.go │ │ │ │ │ │ ├── chtimes_unix.go │ │ │ │ │ │ ├── chtimes_windows.go │ │ │ │ │ │ ├── errors.go │ │ │ │ │ │ ├── events_windows.go │ │ │ │ │ │ ├── exitcode.go │ │ │ │ │ │ ├── filesys.go │ │ │ │ │ │ ├── filesys_windows.go │ │ │ │ │ │ ├── lstat_unix.go │ │ │ │ │ │ ├── lstat_windows.go │ │ │ │ │ │ ├── meminfo.go │ │ │ │ │ │ ├── meminfo_linux.go │ │ │ │ │ │ ├── meminfo_solaris.go │ │ │ │ │ │ ├── meminfo_unsupported.go │ │ │ │ │ │ ├── meminfo_windows.go │ │ │ │ │ │ ├── mknod.go │ │ │ │ │ │ ├── mknod_windows.go │ │ │ │ │ │ ├── path_unix.go │ │ │ │ │ │ ├── path_windows.go │ │ │ │ │ │ ├── process_unix.go │ │ │ │ │ │ ├── rm.go │ │ │ │ │ │ ├── stat_darwin.go │ │ │ │ │ │ ├── stat_freebsd.go │ │ │ │ │ │ ├── stat_linux.go │ │ │ │ │ │ ├── stat_openbsd.go │ │ │ │ │ │ ├── stat_solaris.go │ │ │ │ │ │ ├── stat_unix.go │ │ │ │ │ │ ├── stat_windows.go │ │ │ │ │ │ ├── syscall_unix.go │ │ │ │ │ │ ├── syscall_windows.go │ │ │ │ │ │ ├── umask.go │ │ │ │ │ │ ├── umask_windows.go │ │ │ │ │ │ ├── utimes_freebsd.go │ │ │ │ │ │ ├── utimes_linux.go │ │ │ │ │ │ ├── utimes_unsupported.go │ │ │ │ │ │ ├── xattrs_linux.go │ │ │ │ │ │ └── xattrs_unsupported.go │ │ │ │ │ └── term │ │ │ │ │ │ ├── ascii.go │ │ │ │ │ │ ├── proxy.go │ │ │ │ │ │ ├── tc.go │ │ │ │ │ │ ├── tc_solaris_cgo.go │ │ │ │ │ │ ├── term.go │ │ │ │ │ │ ├── term_windows.go │ │ │ │ │ │ ├── termios_bsd.go │ │ │ │ │ │ ├── termios_linux.go │ │ │ │ │ │ ├── windows │ │ │ │ │ │ ├── ansi_reader.go │ │ │ │ │ │ ├── ansi_writer.go │ │ │ │ │ │ ├── console.go │ │ │ │ │ │ └── windows.go │ │ │ │ │ │ ├── winsize.go │ │ │ │ │ │ └── winsize_solaris_cgo.go │ │ │ │ └── project │ │ │ │ │ └── CONTRIBUTING.md │ │ │ ├── go-connections │ │ │ │ ├── LICENSE │ │ │ │ ├── nat │ │ │ │ │ ├── nat.go │ │ │ │ │ ├── parse.go │ │ │ │ │ └── sort.go │ │ │ │ └── sockets │ │ │ │ │ ├── README.md │ │ │ │ │ ├── inmem_socket.go │ │ │ │ │ ├── proxy.go │ │ │ │ │ ├── sockets.go │ │ │ │ │ ├── sockets_unix.go │ │ │ │ │ ├── sockets_windows.go │ │ │ │ │ ├── tcp_socket.go │ │ │ │ │ └── unix_socket.go │ │ │ ├── go-plugins-helpers │ │ │ │ ├── LICENSE │ │ │ │ ├── NOTICE │ │ │ │ ├── sdk │ │ │ │ │ ├── encoder.go │ │ │ │ │ ├── handler.go │ │ │ │ │ ├── pool.go │ │ │ │ │ ├── spec_file_generator.go │ │ │ │ │ ├── tcp_listener.go │ │ │ │ │ ├── unix_listener.go │ │ │ │ │ ├── unix_listener_nosystemd.go │ │ │ │ │ ├── unix_listener_systemd.go │ │ │ │ │ ├── unix_listener_unsupported.go │ │ │ │ │ ├── windows_listener.go │ │ │ │ │ ├── windows_listener_unsupported.go │ │ │ │ │ └── windows_pipe_config.go │ │ │ │ └── volume │ │ │ │ │ ├── README.md │ │ │ │ │ └── api.go │ │ │ └── go-units │ │ │ │ ├── CONTRIBUTING.md │ │ │ │ ├── LICENSE │ │ │ │ ├── MAINTAINERS │ │ │ │ ├── README.md │ │ │ │ ├── circle.yml │ │ │ │ ├── duration.go │ │ │ │ ├── size.go │ │ │ │ └── ulimit.go │ │ ├── fsouza │ │ │ └── go-dockerclient │ │ │ │ ├── .gitignore │ │ │ │ ├── .travis.yml │ │ │ │ ├── AUTHORS │ │ │ │ ├── DOCKER-LICENSE │ │ │ │ ├── LICENSE │ │ │ │ ├── Makefile │ │ │ │ ├── README.markdown │ │ │ │ ├── appveyor.yml │ │ │ │ ├── auth.go │ │ │ │ ├── change.go │ │ │ │ ├── client.go │ │ │ │ ├── client_unix.go │ │ │ │ ├── client_windows.go │ │ │ │ ├── container.go │ │ │ │ ├── env.go │ │ │ │ ├── event.go │ │ │ │ ├── exec.go │ │ │ │ ├── image.go │ │ │ │ ├── misc.go │ │ │ │ ├── network.go │ │ │ │ ├── node.go │ │ │ │ ├── service.go │ │ │ │ ├── signal.go │ │ │ │ ├── swarm.go │ │ │ │ ├── tar.go │ │ │ │ ├── task.go │ │ │ │ ├── tls.go │ │ │ │ └── volume.go │ │ ├── golang │ │ │ └── mock │ │ │ │ ├── AUTHORS │ │ │ │ ├── CONTRIBUTORS │ │ │ │ ├── LICENSE │ │ │ │ └── gomock │ │ │ │ ├── call.go │ │ │ │ ├── callset.go │ │ │ │ ├── controller.go │ │ │ │ └── matchers.go │ │ ├── jmespath │ │ │ └── go-jmespath │ │ │ │ ├── .gitignore │ │ │ │ ├── .travis.yml │ │ │ │ ├── LICENSE │ │ │ │ ├── Makefile │ │ │ │ ├── README.md │ │ │ │ ├── api.go │ │ │ │ ├── astnodetype_string.go │ │ │ │ ├── functions.go │ │ │ │ ├── interpreter.go │ │ │ │ ├── lexer.go │ │ │ │ ├── parser.go │ │ │ │ ├── toktype_string.go │ │ │ │ └── util.go │ │ ├── opencontainers │ │ │ ├── go-digest │ │ │ │ ├── .mailmap │ │ │ │ ├── .pullapprove.yml │ │ │ │ ├── .travis.yml │ │ │ │ ├── CONTRIBUTING.md │ │ │ │ ├── LICENSE.code │ │ │ │ ├── LICENSE.docs │ │ │ │ ├── MAINTAINERS │ │ │ │ ├── README.md │ │ │ │ ├── algorithm.go │ │ │ │ ├── digest.go │ │ │ │ ├── digester.go │ │ │ │ ├── doc.go │ │ │ │ └── verifiers.go │ │ │ ├── image-spec │ │ │ │ ├── LICENSE │ │ │ │ └── specs-go │ │ │ │ │ ├── v1 │ │ │ │ │ ├── config.go │ │ │ │ │ ├── descriptor.go │ │ │ │ │ ├── index.go │ │ │ │ │ ├── layout.go │ │ │ │ │ ├── manifest.go │ │ │ │ │ └── mediatype.go │ │ │ │ │ ├── version.go │ │ │ │ │ └── versioned.go │ │ │ └── runc │ │ │ │ ├── LICENSE │ │ │ │ ├── NOTICE │ │ │ │ └── libcontainer │ │ │ │ ├── system │ │ │ │ ├── linux.go │ │ │ │ ├── proc.go │ │ │ │ ├── syscall_linux_386.go │ │ │ │ ├── syscall_linux_64.go │ │ │ │ ├── syscall_linux_arm.go │ │ │ │ ├── sysconfig.go │ │ │ │ ├── sysconfig_notcgo.go │ │ │ │ ├── unsupported.go │ │ │ │ └── xattrs_linux.go │ │ │ │ └── user │ │ │ │ ├── MAINTAINERS │ │ │ │ ├── lookup.go │ │ │ │ ├── lookup_unix.go │ │ │ │ ├── lookup_unsupported.go │ │ │ │ └── user.go │ │ ├── pkg │ │ │ └── errors │ │ │ │ ├── .gitignore │ │ │ │ ├── .travis.yml │ │ │ │ ├── LICENSE │ │ │ │ ├── README.md │ │ │ │ ├── appveyor.yml │ │ │ │ ├── errors.go │ │ │ │ └── stack.go │ │ ├── pmezard │ │ │ └── go-difflib │ │ │ │ ├── LICENSE │ │ │ │ └── difflib │ │ │ │ └── difflib.go │ │ └── stretchr │ │ │ └── testify │ │ │ ├── LICENSE │ │ │ ├── assert │ │ │ ├── assertion_format.go │ │ │ ├── assertion_format.go.tmpl │ │ │ ├── assertion_forward.go │ │ │ ├── assertion_forward.go.tmpl │ │ │ ├── assertions.go │ │ │ ├── doc.go │ │ │ ├── errors.go │ │ │ ├── forward_assertions.go │ │ │ └── http_assertions.go │ │ │ └── require │ │ │ ├── doc.go │ │ │ ├── forward_requirements.go │ │ │ ├── require.go │ │ │ ├── require.go.tmpl │ │ │ ├── require_forward.go │ │ │ ├── require_forward.go.tmpl │ │ │ └── requirements.go │ └── golang.org │ │ └── x │ │ ├── net │ │ ├── AUTHORS │ │ ├── CONTRIBUTORS │ │ ├── LICENSE │ │ ├── PATENTS │ │ ├── context │ │ │ ├── context.go │ │ │ ├── ctxhttp │ │ │ │ ├── ctxhttp.go │ │ │ │ └── ctxhttp_pre17.go │ │ │ ├── go17.go │ │ │ └── pre_go17.go │ │ └── proxy │ │ │ ├── direct.go │ │ │ ├── per_host.go │ │ │ ├── proxy.go │ │ │ └── socks5.go │ │ └── sys │ │ ├── AUTHORS │ │ ├── CONTRIBUTORS │ │ ├── LICENSE │ │ ├── PATENTS │ │ ├── unix │ │ ├── .gitignore │ │ ├── README.md │ │ ├── asm_darwin_386.s │ │ ├── asm_darwin_amd64.s │ │ ├── asm_darwin_arm.s │ │ ├── asm_darwin_arm64.s │ │ ├── asm_dragonfly_amd64.s │ │ ├── asm_freebsd_386.s │ │ ├── asm_freebsd_amd64.s │ │ ├── asm_freebsd_arm.s │ │ ├── asm_linux_386.s │ │ ├── asm_linux_amd64.s │ │ ├── asm_linux_arm.s │ │ ├── asm_linux_arm64.s │ │ ├── asm_linux_mips64x.s │ │ ├── asm_linux_mipsx.s │ │ ├── asm_linux_ppc64x.s │ │ ├── asm_linux_s390x.s │ │ ├── asm_netbsd_386.s │ │ ├── asm_netbsd_amd64.s │ │ ├── asm_netbsd_arm.s │ │ ├── asm_openbsd_386.s │ │ ├── asm_openbsd_amd64.s │ │ ├── asm_solaris_amd64.s │ │ ├── bluetooth_linux.go │ │ ├── constants.go │ │ ├── dirent.go │ │ ├── endian_big.go │ │ ├── endian_little.go │ │ ├── env_unix.go │ │ ├── env_unset.go │ │ ├── flock.go │ │ ├── flock_linux_32bit.go │ │ ├── gccgo.go │ │ ├── gccgo_c.c │ │ ├── gccgo_linux_amd64.go │ │ ├── gccgo_linux_sparc64.go │ │ ├── mkall.sh │ │ ├── mkerrors.sh │ │ ├── mkpost.go │ │ ├── mksyscall.pl │ │ ├── mksyscall_solaris.pl │ │ ├── mksysctl_openbsd.pl │ │ ├── mksysnum_darwin.pl │ │ ├── mksysnum_dragonfly.pl │ │ ├── mksysnum_freebsd.pl │ │ ├── mksysnum_netbsd.pl │ │ ├── mksysnum_openbsd.pl │ │ ├── openbsd_pledge.go │ │ ├── race.go │ │ ├── race0.go │ │ ├── sockcmsg_linux.go │ │ ├── sockcmsg_unix.go │ │ ├── str.go │ │ ├── syscall.go │ │ ├── syscall_bsd.go │ │ ├── syscall_darwin.go │ │ ├── syscall_darwin_386.go │ │ ├── syscall_darwin_amd64.go │ │ ├── syscall_darwin_arm.go │ │ ├── syscall_darwin_arm64.go │ │ ├── syscall_dragonfly.go │ │ ├── syscall_dragonfly_amd64.go │ │ ├── syscall_freebsd.go │ │ ├── syscall_freebsd_386.go │ │ ├── syscall_freebsd_amd64.go │ │ ├── syscall_freebsd_arm.go │ │ ├── syscall_linux.go │ │ ├── syscall_linux_386.go │ │ ├── syscall_linux_amd64.go │ │ ├── syscall_linux_amd64_gc.go │ │ ├── syscall_linux_arm.go │ │ ├── syscall_linux_arm64.go │ │ ├── syscall_linux_mips64x.go │ │ ├── syscall_linux_mipsx.go │ │ ├── syscall_linux_ppc64x.go │ │ ├── syscall_linux_s390x.go │ │ ├── syscall_linux_sparc64.go │ │ ├── syscall_netbsd.go │ │ ├── syscall_netbsd_386.go │ │ ├── syscall_netbsd_amd64.go │ │ ├── syscall_netbsd_arm.go │ │ ├── syscall_no_getwd.go │ │ ├── syscall_openbsd.go │ │ ├── syscall_openbsd_386.go │ │ ├── syscall_openbsd_amd64.go │ │ ├── syscall_solaris.go │ │ ├── syscall_solaris_amd64.go │ │ ├── syscall_unix.go │ │ ├── syscall_unix_gc.go │ │ ├── types_darwin.go │ │ ├── types_dragonfly.go │ │ ├── types_freebsd.go │ │ ├── types_netbsd.go │ │ ├── types_openbsd.go │ │ ├── types_solaris.go │ │ ├── zerrors_darwin_386.go │ │ ├── zerrors_darwin_amd64.go │ │ ├── zerrors_darwin_arm.go │ │ ├── zerrors_darwin_arm64.go │ │ ├── zerrors_dragonfly_amd64.go │ │ ├── zerrors_freebsd_386.go │ │ ├── zerrors_freebsd_amd64.go │ │ ├── zerrors_freebsd_arm.go │ │ ├── zerrors_linux_386.go │ │ ├── zerrors_linux_amd64.go │ │ ├── zerrors_linux_arm.go │ │ ├── zerrors_linux_arm64.go │ │ ├── zerrors_linux_mips.go │ │ ├── zerrors_linux_mips64.go │ │ ├── zerrors_linux_mips64le.go │ │ ├── zerrors_linux_mipsle.go │ │ ├── zerrors_linux_ppc64.go │ │ ├── zerrors_linux_ppc64le.go │ │ ├── zerrors_linux_s390x.go │ │ ├── zerrors_linux_sparc64.go │ │ ├── zerrors_netbsd_386.go │ │ ├── zerrors_netbsd_amd64.go │ │ ├── zerrors_netbsd_arm.go │ │ ├── zerrors_openbsd_386.go │ │ ├── zerrors_openbsd_amd64.go │ │ ├── zerrors_solaris_amd64.go │ │ ├── zsyscall_darwin_386.go │ │ ├── zsyscall_darwin_amd64.go │ │ ├── zsyscall_darwin_arm.go │ │ ├── zsyscall_darwin_arm64.go │ │ ├── zsyscall_dragonfly_amd64.go │ │ ├── zsyscall_freebsd_386.go │ │ ├── zsyscall_freebsd_amd64.go │ │ ├── zsyscall_freebsd_arm.go │ │ ├── zsyscall_linux_386.go │ │ ├── zsyscall_linux_amd64.go │ │ ├── zsyscall_linux_arm.go │ │ ├── zsyscall_linux_arm64.go │ │ ├── zsyscall_linux_mips.go │ │ ├── zsyscall_linux_mips64.go │ │ ├── zsyscall_linux_mips64le.go │ │ ├── zsyscall_linux_mipsle.go │ │ ├── zsyscall_linux_ppc64.go │ │ ├── zsyscall_linux_ppc64le.go │ │ ├── zsyscall_linux_s390x.go │ │ ├── zsyscall_linux_sparc64.go │ │ ├── zsyscall_netbsd_386.go │ │ ├── zsyscall_netbsd_amd64.go │ │ ├── zsyscall_netbsd_arm.go │ │ ├── zsyscall_openbsd_386.go │ │ ├── zsyscall_openbsd_amd64.go │ │ ├── zsyscall_solaris_amd64.go │ │ ├── zsysctl_openbsd.go │ │ ├── zsysnum_darwin_386.go │ │ ├── zsysnum_darwin_amd64.go │ │ ├── zsysnum_darwin_arm.go │ │ ├── zsysnum_darwin_arm64.go │ │ ├── zsysnum_dragonfly_amd64.go │ │ ├── zsysnum_freebsd_386.go │ │ ├── zsysnum_freebsd_amd64.go │ │ ├── zsysnum_freebsd_arm.go │ │ ├── zsysnum_linux_386.go │ │ ├── zsysnum_linux_amd64.go │ │ ├── zsysnum_linux_arm.go │ │ ├── zsysnum_linux_arm64.go │ │ ├── zsysnum_linux_mips.go │ │ ├── zsysnum_linux_mips64.go │ │ ├── zsysnum_linux_mips64le.go │ │ ├── zsysnum_linux_mipsle.go │ │ ├── zsysnum_linux_ppc64.go │ │ ├── zsysnum_linux_ppc64le.go │ │ ├── zsysnum_linux_s390x.go │ │ ├── zsysnum_linux_sparc64.go │ │ ├── zsysnum_netbsd_386.go │ │ ├── zsysnum_netbsd_amd64.go │ │ ├── zsysnum_netbsd_arm.go │ │ ├── zsysnum_openbsd_386.go │ │ ├── zsysnum_openbsd_amd64.go │ │ ├── zsysnum_solaris_amd64.go │ │ ├── ztypes_darwin_386.go │ │ ├── ztypes_darwin_amd64.go │ │ ├── ztypes_darwin_arm.go │ │ ├── ztypes_darwin_arm64.go │ │ ├── ztypes_dragonfly_amd64.go │ │ ├── ztypes_freebsd_386.go │ │ ├── ztypes_freebsd_amd64.go │ │ ├── ztypes_freebsd_arm.go │ │ ├── ztypes_linux_386.go │ │ ├── ztypes_linux_amd64.go │ │ ├── ztypes_linux_arm.go │ │ ├── ztypes_linux_arm64.go │ │ ├── ztypes_linux_mips.go │ │ ├── ztypes_linux_mips64.go │ │ ├── ztypes_linux_mips64le.go │ │ ├── ztypes_linux_mipsle.go │ │ ├── ztypes_linux_ppc64.go │ │ ├── ztypes_linux_ppc64le.go │ │ ├── ztypes_linux_s390x.go │ │ ├── ztypes_linux_sparc64.go │ │ ├── ztypes_netbsd_386.go │ │ ├── ztypes_netbsd_amd64.go │ │ ├── ztypes_netbsd_arm.go │ │ ├── ztypes_openbsd_386.go │ │ ├── ztypes_openbsd_amd64.go │ │ └── ztypes_solaris_amd64.go │ │ └── windows │ │ ├── asm_windows_386.s │ │ ├── asm_windows_amd64.s │ │ ├── dll_windows.go │ │ ├── env_unset.go │ │ ├── env_windows.go │ │ ├── eventlog.go │ │ ├── exec_windows.go │ │ ├── mksyscall.go │ │ ├── race.go │ │ ├── race0.go │ │ ├── security_windows.go │ │ ├── service.go │ │ ├── str.go │ │ ├── syscall.go │ │ ├── syscall_windows.go │ │ ├── zsyscall_windows.go │ │ ├── ztypes_windows.go │ │ ├── ztypes_windows_386.go │ │ └── ztypes_windows_amd64.go ├── version │ ├── formatting.go │ └── version.go └── volumes │ ├── amazon-ecs-volume-plugin │ └── plugin.go │ ├── ecs_volume_driver.go │ ├── ecs_volume_driver_test.go │ ├── ecs_volume_plugin.go │ ├── ecs_volume_plugin_test.go │ ├── efs_mount_helper.go │ ├── efs_mount_helper_test.go │ ├── logger │ ├── log.go │ └── log_test.go │ ├── state_manager.go │ └── state_manager_test.go ├── packaging ├── amazon-linux-ami │ ├── amazon-ecs-volume-plugin.conf │ ├── amazon-ecs-volume-plugin.service │ ├── amazon-ecs-volume-plugin.socket │ ├── ecs-init.spec │ ├── ecs.conf │ └── ecs.service ├── generic-deb │ └── debian │ │ ├── README.source │ │ ├── amazon-ecs-init.install │ │ ├── amazon-ecs-init.manpages │ │ ├── amazon-ecs-volume-plugin.service │ │ ├── amazon-ecs-volume-plugin.socket │ │ ├── changelog │ │ ├── compat │ │ ├── control │ │ ├── copyright │ │ ├── dirs │ │ ├── docs │ │ ├── ecs.service │ │ ├── rules │ │ └── source │ │ ├── format │ │ └── include-binaries ├── generic-rpm │ ├── README.md │ ├── amazon-ecs-init.spec │ ├── amazon-ecs-volume-plugin.service │ ├── amazon-ecs-volume-plugin.socket │ └── ecs.service └── suse │ ├── amazon-ecs-init.changes │ ├── amazon-ecs-init.spec │ └── amazon-ecs.service ├── scripts ├── amazon-ecs-agent.gpg ├── amazon-ecs-init.1 ├── amazon-ssm-agent.gpg ├── analyze-cover-profile ├── bundle_log_config.sh ├── changelog │ ├── CHANGELOG_MASTER │ ├── README.md │ └── changelog.go ├── dockerfiles │ ├── build.dockerfile │ ├── exit-success.dockerfile │ ├── mock-agent.dockerfile │ ├── test.dockerfile │ └── wants-update.dockerfile ├── ecs-anywhere-install.sh ├── gobuild.sh ├── mock-ecs-agent.sh ├── mockgen.sh ├── test └── update-version.sh └── seelog.xml /.gitallowed: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aws/amazon-ecs-init/9332428bb18f16788bc6a905c61c17736937f6b8/.gitallowed -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: Build 2 | 3 | on: [pull_request] 4 | 5 | jobs: 6 | build: 7 | name: CI Build 8 | runs-on: ubuntu-latest 9 | steps: 10 | - uses: actions/setup-go@v2 11 | with: 12 | go-version: 1.15.4 13 | - uses: actions/checkout@v2 14 | with: 15 | path: src/github.com/aws/amazon-ecs-init 16 | - name: run checks 17 | run: | 18 | export GOPATH=$GITHUB_WORKSPACE 19 | export PATH=$PATH:$(go env GOPATH)/bin 20 | cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-init 21 | make get-deps 22 | make static-check 23 | make test 24 | make analyze-cover-profile 25 | -------------------------------------------------------------------------------- /.github/workflows/gitsecrets.yml: -------------------------------------------------------------------------------- 1 | name: GitSecretsScan 2 | 3 | on: [push, pull_request] 4 | 5 | jobs: 6 | git-secret-check: 7 | name: Git Secrets Scan 8 | runs-on: ubuntu-latest 9 | steps: 10 | - uses: actions/checkout@v2 11 | with: 12 | path: src/github.com/aws/amazon-ecs-init 13 | - name: Git Secrets Scan Script 14 | run: | 15 | set -ex 16 | cd $GITHUB_WORKSPACE 17 | git clone https://github.com/awslabs/git-secrets.git && cd git-secrets 18 | sudo make install 19 | git secrets --register-aws --global 20 | cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-init 21 | git secrets --install 22 | git secrets --register-aws 23 | git secrets --scan-history 24 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /amazon-ecs-init* 2 | /BUILDROOT/ 3 | /x86_64/ 4 | /sources.tar 5 | /ecs-init-* 6 | *.swp 7 | /ecs.conf 8 | /.deb-done 9 | /.rpm-done 10 | /.srpm-done 11 | /BUILD 12 | /RPMS 13 | /SOURCES 14 | /SRPMS 15 | /ecs-init.spec 16 | /sources.tgz 17 | ecs-agent-*.tar 18 | /ecs.service 19 | *.log 20 | .idea/ 21 | cover.out 22 | coverprofile.out 23 | *.DS_Store -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go_import_path: github.com/aws/amazon-ecs-init 3 | sudo: false 4 | go: 5 | - 1.15 6 | 7 | matrix: 8 | include: 9 | - os: linux 10 | script: 11 | - make get-deps 12 | - make static-check 13 | - make test 14 | - make analyze-cover-profile 15 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | ## Code of Conduct 2 | This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). 3 | For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact 4 | opensource-codeofconduct@amazon.com with any additional questions or comments. 5 | -------------------------------------------------------------------------------- /NOTICE: -------------------------------------------------------------------------------- 1 | Amazon Elastic Container Service RPM 2 | Copyright 2014-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | -------------------------------------------------------------------------------- /ecs-init/ECSVERSION: -------------------------------------------------------------------------------- 1 | 1.63.1 2 | -------------------------------------------------------------------------------- /ecs-init/Gopkg.toml: -------------------------------------------------------------------------------- 1 | # Gopkg.toml example 2 | # 3 | # Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md 4 | # for detailed Gopkg.toml documentation. 5 | # 6 | # required = ["github.com/user/thing/cmd/thing"] 7 | # ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"] 8 | # 9 | # [[constraint]] 10 | # name = "github.com/user/project" 11 | # version = "1.0.0" 12 | # 13 | # [[constraint]] 14 | # name = "github.com/user/project2" 15 | # branch = "dev" 16 | # source = "github.com/myfork/project2" 17 | # 18 | # [[override]] 19 | # name = "github.com/x/y" 20 | # version = "2.4.0" 21 | # 22 | # [prune] 23 | # non-go = false 24 | # go-tests = true 25 | # unused-packages = true 26 | 27 | 28 | [[constraint]] 29 | branch = "master" 30 | name = "github.com/cihub/seelog" 31 | 32 | [[constraint]] 33 | name = "github.com/golang/mock" 34 | version = "1.3.1" 35 | 36 | [[constraint]] 37 | name = "github.com/aws/aws-sdk-go" 38 | version = "v1.36.0" 39 | 40 | [prune] 41 | go-tests = true 42 | unused-packages = true 43 | -------------------------------------------------------------------------------- /ecs-init/cmd/cmd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"). You may 4 | // not use this file except in compliance with the License. A copy of the 5 | // License is located at 6 | // 7 | // http://aws.amazon.com/apache2.0/ 8 | // 9 | // or in the "license" file accompanying this file. This file is distributed 10 | // on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 11 | // express or implied. See the License for the specific language governing 12 | // permissions and limitations under the License. 13 | 14 | package cmd 15 | 16 | //go:generate mockgen.sh sysctl $GOFILE ../exec/sysctl 17 | //go:generate mockgen.sh iptables $GOFILE ../exec/iptables 18 | 19 | // Cmd defines common methods from exec.Cmd that are used to run external 20 | // commands 21 | type Cmd interface { 22 | CombinedOutput() ([]byte, error) 23 | Output() ([]byte, error) 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/config/config_al2.go: -------------------------------------------------------------------------------- 1 | // +build al2 2 | 3 | // Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | // 5 | // Licensed under the Apache License, Version 2.0 (the "License"). You may 6 | // not use this file except in compliance with the License. A copy of the 7 | // License is located at 8 | // 9 | // http://aws.amazon.com/apache2.0/ 10 | // 11 | // or in the "license" file accompanying this file. This file is distributed 12 | // on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 13 | // express or implied. See the License for the specific language governing 14 | // permissions and limitations under the License. 15 | 16 | package config 17 | 18 | const ( 19 | cgroupMountpoint = "/sys/fs/cgroup" 20 | hostCertsDirPath = "/etc/pki/tls/certs" 21 | hostPKIDirPath = "/etc/pki" 22 | ) 23 | -------------------------------------------------------------------------------- /ecs-init/config/config_generic_rpm.go: -------------------------------------------------------------------------------- 1 | // +build generic_rpm 2 | 3 | // Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | // 5 | // Licensed under the Apache License, Version 2.0 (the "License"). You may 6 | // not use this file except in compliance with the License. A copy of the 7 | // License is located at 8 | // 9 | // http://aws.amazon.com/apache2.0/ 10 | // 11 | // or in the "license" file accompanying this file. This file is distributed 12 | // on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 13 | // express or implied. See the License for the specific language governing 14 | // permissions and limitations under the License. 15 | 16 | package config 17 | 18 | // This file contains the config used for generic rpm build. 19 | 20 | const ( 21 | cgroupMountpoint = "/sys/fs/cgroup" 22 | hostCertsDirPath = "" 23 | hostPKIDirPath = "" 24 | ) 25 | -------------------------------------------------------------------------------- /ecs-init/config/config_suse_ubuntu_debian.go: -------------------------------------------------------------------------------- 1 | // +build suse ubuntu debian 2 | 3 | // Copyright 2017-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | // 5 | // Licensed under the Apache License, Version 2.0 (the "License"). You may 6 | // not use this file except in compliance with the License. A copy of the 7 | // License is located at 8 | // 9 | // http://aws.amazon.com/apache2.0/ 10 | // 11 | // or in the "license" file accompanying this file. This file is distributed 12 | // on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 13 | // express or implied. See the License for the specific language governing 14 | // permissions and limitations under the License. 15 | 16 | package config 17 | 18 | const ( 19 | cgroupMountpoint = "/sys/fs/cgroup" 20 | hostCertsDirPath = "/etc/ssl/certs" 21 | hostPKIDirPath = "/etc/ssl" 22 | ) 23 | -------------------------------------------------------------------------------- /ecs-init/config/config_unspecified.go: -------------------------------------------------------------------------------- 1 | // +build !suse,!ubuntu,!al2,!debian,!generic_rpm 2 | 3 | // Copyright 2017-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | // 5 | // Licensed under the Apache License, Version 2.0 (the "License"). You may 6 | // not use this file except in compliance with the License. A copy of the 7 | // License is located at 8 | // 9 | // http://aws.amazon.com/apache2.0/ 10 | // 11 | // or in the "license" file accompanying this file. This file is distributed 12 | // on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 13 | // express or implied. See the License for the specific language governing 14 | // permissions and limitations under the License. 15 | 16 | // this is primarily here for al1 builds 17 | 18 | package config 19 | 20 | const ( 21 | cgroupMountpoint = "/cgroup" 22 | hostCertsDirPath = "/etc/pki/tls/certs" 23 | hostPKIDirPath = "/etc/pki" 24 | ) 25 | -------------------------------------------------------------------------------- /ecs-init/config/release.go: -------------------------------------------------------------------------------- 1 | // +build !development 2 | 3 | // Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | // 5 | // Licensed under the Apache License, Version 2.0 (the "License"). You may 6 | // not use this file except in compliance with the License. A copy of the 7 | // License is located at 8 | // 9 | // http://aws.amazon.com/apache2.0/ 10 | // 11 | // or in the "license" file accompanying this file. This file is distributed 12 | // on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 13 | // express or implied. See the License for the specific language governing 14 | // permissions and limitations under the License. 15 | 16 | package config 17 | 18 | const ( 19 | directoryPrefix = "" 20 | s3Bucket = "amazon-ecs-agent" 21 | ) 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Azure/go-ansiterm/context.go: -------------------------------------------------------------------------------- 1 | package ansiterm 2 | 3 | type ansiContext struct { 4 | currentChar byte 5 | paramBuffer []byte 6 | interBuffer []byte 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Azure/go-ansiterm/csi_param_state.go: -------------------------------------------------------------------------------- 1 | package ansiterm 2 | 3 | type csiParamState struct { 4 | baseState 5 | } 6 | 7 | func (csiState csiParamState) Handle(b byte) (s state, e error) { 8 | logger.Infof("CsiParam::Handle %#x", b) 9 | 10 | nextState, err := csiState.baseState.Handle(b) 11 | if nextState != nil || err != nil { 12 | return nextState, err 13 | } 14 | 15 | switch { 16 | case sliceContains(alphabetics, b): 17 | return csiState.parser.ground, nil 18 | case sliceContains(csiCollectables, b): 19 | csiState.parser.collectParam() 20 | return csiState, nil 21 | case sliceContains(executors, b): 22 | return csiState, csiState.parser.execute() 23 | } 24 | 25 | return csiState, nil 26 | } 27 | 28 | func (csiState csiParamState) Transition(s state) error { 29 | logger.Infof("CsiParam::Transition %s --> %s", csiState.Name(), s.Name()) 30 | csiState.baseState.Transition(s) 31 | 32 | switch s { 33 | case csiState.parser.ground: 34 | return csiState.parser.csiDispatch() 35 | } 36 | 37 | return nil 38 | } 39 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Azure/go-ansiterm/ground_state.go: -------------------------------------------------------------------------------- 1 | package ansiterm 2 | 3 | type groundState struct { 4 | baseState 5 | } 6 | 7 | func (gs groundState) Handle(b byte) (s state, e error) { 8 | gs.parser.context.currentChar = b 9 | 10 | nextState, err := gs.baseState.Handle(b) 11 | if nextState != nil || err != nil { 12 | return nextState, err 13 | } 14 | 15 | switch { 16 | case sliceContains(printables, b): 17 | return gs, gs.parser.print() 18 | 19 | case sliceContains(executors, b): 20 | return gs, gs.parser.execute() 21 | } 22 | 23 | return gs, nil 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Azure/go-ansiterm/osc_string_state.go: -------------------------------------------------------------------------------- 1 | package ansiterm 2 | 3 | type oscStringState struct { 4 | baseState 5 | } 6 | 7 | func (oscState oscStringState) Handle(b byte) (s state, e error) { 8 | logger.Infof("OscString::Handle %#x", b) 9 | nextState, err := oscState.baseState.Handle(b) 10 | if nextState != nil || err != nil { 11 | return nextState, err 12 | } 13 | 14 | switch { 15 | case isOscStringTerminator(b): 16 | return oscState.parser.ground, nil 17 | } 18 | 19 | return oscState, nil 20 | } 21 | 22 | // See below for OSC string terminators for linux 23 | // http://man7.org/linux/man-pages/man4/console_codes.4.html 24 | func isOscStringTerminator(b byte) bool { 25 | 26 | if b == ANSI_BEL || b == 0x5C { 27 | return true 28 | } 29 | 30 | return false 31 | } 32 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Azure/go-ansiterm/utilities.go: -------------------------------------------------------------------------------- 1 | package ansiterm 2 | 3 | import ( 4 | "strconv" 5 | ) 6 | 7 | func sliceContains(bytes []byte, b byte) bool { 8 | for _, v := range bytes { 9 | if v == b { 10 | return true 11 | } 12 | } 13 | 14 | return false 15 | } 16 | 17 | func convertBytesToInteger(bytes []byte) int { 18 | s := string(bytes) 19 | i, _ := strconv.Atoi(s) 20 | return i 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Azure/go-ansiterm/winterm/utilities.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package winterm 4 | 5 | // AddInRange increments a value by the passed quantity while ensuring the values 6 | // always remain within the supplied min / max range. 7 | func addInRange(n int16, increment int16, min int16, max int16) int16 { 8 | return ensureInRange(n+increment, min, max) 9 | } 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Microsoft/go-winio/.gitignore: -------------------------------------------------------------------------------- 1 | *.exe 2 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Microsoft/go-winio/syscall.go: -------------------------------------------------------------------------------- 1 | package winio 2 | 3 | //go:generate go run $GOROOT/src/syscall/mksyscall_windows.go -output zsyscall_windows.go file.go pipe.go sd.go fileinfo.go privilege.go backup.go 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/NVIDIA/gpu-monitoring-tools/bindings/go/nvml/nvml_dl.h: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2015-2018, NVIDIA CORPORATION. All rights reserved. 2 | 3 | #ifndef _NVML_DL_H_ 4 | #define _NVML_DL_H_ 5 | 6 | #include "nvml.h" 7 | 8 | #define NVML_DL(x) x##_dl 9 | 10 | extern nvmlReturn_t NVML_DL(nvmlInit)(void); 11 | extern nvmlReturn_t NVML_DL(nvmlShutdown)(void); 12 | extern nvmlReturn_t NVML_DL(nvmlDeviceGetTopologyCommonAncestor)( 13 | nvmlDevice_t, nvmlDevice_t, nvmlGpuTopologyLevel_t *); 14 | 15 | #endif // _NVML_DL_H_ 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Nvveen/Gotty/README: -------------------------------------------------------------------------------- 1 | Gotty is a library written in Go that determines and reads termcap database 2 | files to produce an interface for interacting with the capabilities of a 3 | terminal. 4 | See the godoc documentation or the source code for more information about 5 | function usage. 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Nvveen/Gotty/TODO: -------------------------------------------------------------------------------- 1 | gotty.go:// TODO add more concurrency to name lookup, look for more opportunities. 2 | all:// TODO add more documentation, with function usage in a doc.go file. 3 | all:// TODO add more testing/benchmarking with go test. 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Nvveen/Gotty/types.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 Neal van Veen. All rights reserved. 2 | // Usage of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | package gotty 6 | 7 | type TermInfo struct { 8 | boolAttributes map[string]bool 9 | numAttributes map[string]int16 10 | strAttributes map[string]string 11 | // The various names of the TermInfo file. 12 | Names []string 13 | } 14 | 15 | type stacker interface { 16 | } 17 | type stack []stacker 18 | 19 | type parser struct { 20 | st stack 21 | parameters []stacker 22 | dynamicVar map[byte]stacker 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/.gitignore: -------------------------------------------------------------------------------- 1 | logrus 2 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - 1.6.x 4 | - 1.7.x 5 | - 1.8.x 6 | - tip 7 | env: 8 | - GOMAXPROCS=4 GORACE=halt_on_error=1 9 | install: 10 | - go get github.com/stretchr/testify/assert 11 | script: 12 | - go test -race -v . 13 | - cd hooks/null && go test -race -v . 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/doc.go: -------------------------------------------------------------------------------- 1 | /* 2 | Package logrus is a structured logger for Go, completely API compatible with the standard library logger. 3 | 4 | 5 | The simplest way to use Logrus is simply the package-level exported logger: 6 | 7 | package main 8 | 9 | import ( 10 | log "github.com/sirupsen/logrus" 11 | ) 12 | 13 | func main() { 14 | log.WithFields(log.Fields{ 15 | "animal": "walrus", 16 | "number": 1, 17 | "size": 10, 18 | }).Info("A walrus appears") 19 | } 20 | 21 | Output: 22 | time="2015-09-07T08:48:33Z" level=info msg="A walrus appears" animal=walrus number=1 size=10 23 | 24 | For a full guide visit https://github.com/sirupsen/logrus 25 | */ 26 | package logrus 27 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/terminal_appengine.go: -------------------------------------------------------------------------------- 1 | // +build appengine 2 | 3 | package logrus 4 | 5 | import "io" 6 | 7 | // IsTerminal returns true if stderr's file descriptor is a terminal. 8 | func IsTerminal(f io.Writer) bool { 9 | return true 10 | } 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/terminal_bsd.go: -------------------------------------------------------------------------------- 1 | // +build darwin freebsd openbsd netbsd dragonfly 2 | // +build !appengine 3 | 4 | package logrus 5 | 6 | import "syscall" 7 | 8 | const ioctlReadTermios = syscall.TIOCGETA 9 | 10 | type Termios syscall.Termios 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/terminal_linux.go: -------------------------------------------------------------------------------- 1 | // Based on ssh/terminal: 2 | // Copyright 2013 The Go Authors. All rights reserved. 3 | // Use of this source code is governed by a BSD-style 4 | // license that can be found in the LICENSE file. 5 | 6 | // +build !appengine 7 | 8 | package logrus 9 | 10 | import "syscall" 11 | 12 | const ioctlReadTermios = syscall.TCGETS 13 | 14 | type Termios syscall.Termios 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/terminal_notwindows.go: -------------------------------------------------------------------------------- 1 | // Based on ssh/terminal: 2 | // Copyright 2011 The Go Authors. All rights reserved. 3 | // Use of this source code is governed by a BSD-style 4 | // license that can be found in the LICENSE file. 5 | 6 | // +build linux darwin freebsd openbsd netbsd dragonfly 7 | // +build !appengine 8 | 9 | package logrus 10 | 11 | import ( 12 | "io" 13 | "os" 14 | "syscall" 15 | "unsafe" 16 | ) 17 | 18 | // IsTerminal returns true if stderr's file descriptor is a terminal. 19 | func IsTerminal(f io.Writer) bool { 20 | var termios Termios 21 | switch v := f.(type) { 22 | case *os.File: 23 | _, _, err := syscall.Syscall6(syscall.SYS_IOCTL, uintptr(v.Fd()), ioctlReadTermios, uintptr(unsafe.Pointer(&termios)), 0, 0, 0) 24 | return err == 0 25 | default: 26 | return false 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/Sirupsen/logrus/terminal_solaris.go: -------------------------------------------------------------------------------- 1 | // +build solaris,!appengine 2 | 3 | package logrus 4 | 5 | import ( 6 | "io" 7 | "os" 8 | 9 | "golang.org/x/sys/unix" 10 | ) 11 | 12 | // IsTerminal returns true if the given file descriptor is a terminal. 13 | func IsTerminal(f io.Writer) bool { 14 | switch v := f.(type) { 15 | case *os.File: 16 | _, err := unix.IoctlGetTermios(int(v.Fd()), unix.TCGETA) 17 | return err == nil 18 | default: 19 | return false 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/NOTICE.txt: -------------------------------------------------------------------------------- 1 | AWS SDK for Go 2 | Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | Copyright 2014-2015 Stripe, Inc. 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/client/metadata/client_info.go: -------------------------------------------------------------------------------- 1 | package metadata 2 | 3 | // ClientInfo wraps immutable data from the client.Client structure. 4 | type ClientInfo struct { 5 | ServiceName string 6 | ServiceID string 7 | APIVersion string 8 | PartitionID string 9 | Endpoint string 10 | SigningName string 11 | SigningRegion string 12 | JSONVersion string 13 | TargetPrefix string 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/client/no_op_retryer.go: -------------------------------------------------------------------------------- 1 | package client 2 | 3 | import ( 4 | "time" 5 | 6 | "github.com/aws/aws-sdk-go/aws/request" 7 | ) 8 | 9 | // NoOpRetryer provides a retryer that performs no retries. 10 | // It should be used when we do not want retries to be performed. 11 | type NoOpRetryer struct{} 12 | 13 | // MaxRetries returns the number of maximum returns the service will use to make 14 | // an individual API; For NoOpRetryer the MaxRetries will always be zero. 15 | func (d NoOpRetryer) MaxRetries() int { 16 | return 0 17 | } 18 | 19 | // ShouldRetry will always return false for NoOpRetryer, as it should never retry. 20 | func (d NoOpRetryer) ShouldRetry(_ *request.Request) bool { 21 | return false 22 | } 23 | 24 | // RetryRules returns the delay duration before retrying this request again; 25 | // since NoOpRetryer does not retry, RetryRules always returns 0. 26 | func (d NoOpRetryer) RetryRules(_ *request.Request) time.Duration { 27 | return 0 28 | } 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go: -------------------------------------------------------------------------------- 1 | // +build go1.9 2 | 3 | package aws 4 | 5 | import "context" 6 | 7 | // Context is an alias of the Go stdlib's context.Context interface. 8 | // It can be used within the SDK's API operation "WithContext" methods. 9 | // 10 | // See https://golang.org/pkg/context on how to use contexts. 11 | type Context = context.Context 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go: -------------------------------------------------------------------------------- 1 | // +build !go1.7 2 | 3 | package aws 4 | 5 | import ( 6 | "github.com/aws/aws-sdk-go/internal/context" 7 | ) 8 | 9 | // BackgroundContext returns a context that will never be canceled, has no 10 | // values, and no deadline. This context is used by the SDK to provide 11 | // backwards compatibility with non-context API operations and functionality. 12 | // 13 | // Go 1.6 and before: 14 | // This context function is equivalent to context.Background in the Go stdlib. 15 | // 16 | // Go 1.7 and later: 17 | // The context returned will be the value returned by context.Background() 18 | // 19 | // See https://golang.org/pkg/context for more information on Contexts. 20 | func BackgroundContext() Context { 21 | return context.BackgroundCtx 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go: -------------------------------------------------------------------------------- 1 | // +build go1.7 2 | 3 | package aws 4 | 5 | import "context" 6 | 7 | // BackgroundContext returns a context that will never be canceled, has no 8 | // values, and no deadline. This context is used by the SDK to provide 9 | // backwards compatibility with non-context API operations and functionality. 10 | // 11 | // Go 1.6 and before: 12 | // This context function is equivalent to context.Background in the Go stdlib. 13 | // 14 | // Go 1.7 and later: 15 | // The context returned will be the value returned by context.Background() 16 | // 17 | // See https://golang.org/pkg/context for more information on Contexts. 18 | func BackgroundContext() Context { 19 | return context.Background() 20 | } 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go: -------------------------------------------------------------------------------- 1 | package aws 2 | 3 | import ( 4 | "time" 5 | ) 6 | 7 | // SleepWithContext will wait for the timer duration to expire, or the context 8 | // is canceled. Which ever happens first. If the context is canceled the Context's 9 | // error will be returned. 10 | // 11 | // Expects Context to always return a non-nil error if the Done channel is closed. 12 | func SleepWithContext(ctx Context, dur time.Duration) error { 13 | t := time.NewTimer(dur) 14 | defer t.Stop() 15 | 16 | select { 17 | case <-t.C: 18 | break 19 | case <-ctx.Done(): 20 | return ctx.Err() 21 | } 22 | 23 | return nil 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/param_validator.go: -------------------------------------------------------------------------------- 1 | package corehandlers 2 | 3 | import "github.com/aws/aws-sdk-go/aws/request" 4 | 5 | // ValidateParametersHandler is a request handler to validate the input parameters. 6 | // Validating parameters only has meaning if done prior to the request being sent. 7 | var ValidateParametersHandler = request.NamedHandler{Name: "core.ValidateParametersHandler", Fn: func(r *request.Request) { 8 | if !r.ParamsFilled() { 9 | return 10 | } 11 | 12 | if v, ok := r.Params.(request.Validator); ok { 13 | if err := v.Validate(); err != nil { 14 | r.Error = err 15 | } 16 | } 17 | }} 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.5.go: -------------------------------------------------------------------------------- 1 | // +build !go1.7 2 | 3 | package credentials 4 | 5 | import ( 6 | "github.com/aws/aws-sdk-go/internal/context" 7 | ) 8 | 9 | // backgroundContext returns a context that will never be canceled, has no 10 | // values, and no deadline. This context is used by the SDK to provide 11 | // backwards compatibility with non-context API operations and functionality. 12 | // 13 | // Go 1.6 and before: 14 | // This context function is equivalent to context.Background in the Go stdlib. 15 | // 16 | // Go 1.7 and later: 17 | // The context returned will be the value returned by context.Background() 18 | // 19 | // See https://golang.org/pkg/context for more information on Contexts. 20 | func backgroundContext() Context { 21 | return context.BackgroundCtx 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.7.go: -------------------------------------------------------------------------------- 1 | // +build go1.7 2 | 3 | package credentials 4 | 5 | import "context" 6 | 7 | // backgroundContext returns a context that will never be canceled, has no 8 | // values, and no deadline. This context is used by the SDK to provide 9 | // backwards compatibility with non-context API operations and functionality. 10 | // 11 | // Go 1.6 and before: 12 | // This context function is equivalent to context.Background in the Go stdlib. 13 | // 14 | // Go 1.7 and later: 15 | // The context returned will be the value returned by context.Background() 16 | // 17 | // See https://golang.org/pkg/context for more information on Contexts. 18 | func backgroundContext() Context { 19 | return context.Background() 20 | } 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.9.go: -------------------------------------------------------------------------------- 1 | // +build go1.9 2 | 3 | package credentials 4 | 5 | import "context" 6 | 7 | // Context is an alias of the Go stdlib's context.Context interface. 8 | // It can be used within the SDK's API operation "WithContext" methods. 9 | // 10 | // This type, aws.Context, and context.Context are equivalent. 11 | // 12 | // See https://golang.org/pkg/context on how to use contexts. 13 | type Context = context.Context 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/credentials/example.ini: -------------------------------------------------------------------------------- 1 | [default] 2 | aws_access_key_id = accessKey 3 | aws_secret_access_key = secret 4 | aws_session_token = token 5 | 6 | [no_token] 7 | aws_access_key_id = accessKey 8 | aws_secret_access_key = secret 9 | 10 | [with_colon] 11 | aws_access_key_id: accessKey 12 | aws_secret_access_key: secret 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go: -------------------------------------------------------------------------------- 1 | package csm 2 | 3 | type metricException interface { 4 | Exception() string 5 | Message() string 6 | } 7 | 8 | type requestException struct { 9 | exception string 10 | message string 11 | } 12 | 13 | func (e requestException) Exception() string { 14 | return e.exception 15 | } 16 | func (e requestException) Message() string { 17 | return e.message 18 | } 19 | 20 | type awsException struct { 21 | requestException 22 | } 23 | 24 | type sdkException struct { 25 | requestException 26 | } 27 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/defaults/shared_config.go: -------------------------------------------------------------------------------- 1 | package defaults 2 | 3 | import ( 4 | "github.com/aws/aws-sdk-go/internal/shareddefaults" 5 | ) 6 | 7 | // SharedCredentialsFilename returns the SDK's default file path 8 | // for the shared credentials file. 9 | // 10 | // Builds the shared config file path based on the OS's platform. 11 | // 12 | // - Linux/Unix: $HOME/.aws/credentials 13 | // - Windows: %USERPROFILE%\.aws\credentials 14 | func SharedCredentialsFilename() string { 15 | return shareddefaults.SharedCredentialsFilename() 16 | } 17 | 18 | // SharedConfigFilename returns the SDK's default file path for 19 | // the shared config file. 20 | // 21 | // Builds the shared config file path based on the OS's platform. 22 | // 23 | // - Linux/Unix: $HOME/.aws/config 24 | // - Windows: %USERPROFILE%\.aws\config 25 | func SharedConfigFilename() string { 26 | return shareddefaults.SharedConfigFilename() 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/endpoints/legacy_regions.go: -------------------------------------------------------------------------------- 1 | package endpoints 2 | 3 | var legacyGlobalRegions = map[string]map[string]struct{}{ 4 | "sts": { 5 | "ap-northeast-1": {}, 6 | "ap-south-1": {}, 7 | "ap-southeast-1": {}, 8 | "ap-southeast-2": {}, 9 | "ca-central-1": {}, 10 | "eu-central-1": {}, 11 | "eu-north-1": {}, 12 | "eu-west-1": {}, 13 | "eu-west-2": {}, 14 | "eu-west-3": {}, 15 | "sa-east-1": {}, 16 | "us-east-1": {}, 17 | "us-east-2": {}, 18 | "us-west-1": {}, 19 | "us-west-2": {}, 20 | }, 21 | "s3": { 22 | "us-east-1": {}, 23 | }, 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/errors.go: -------------------------------------------------------------------------------- 1 | package aws 2 | 3 | import "github.com/aws/aws-sdk-go/aws/awserr" 4 | 5 | var ( 6 | // ErrMissingRegion is an error that is returned if region configuration is 7 | // not found. 8 | ErrMissingRegion = awserr.New("MissingRegion", "could not find region configuration", nil) 9 | 10 | // ErrMissingEndpoint is an error that is returned if an endpoint cannot be 11 | // resolved for a service. 12 | ErrMissingEndpoint = awserr.New("MissingEndpoint", "'Endpoint' configuration is required for this service", nil) 13 | ) 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/jsonvalue.go: -------------------------------------------------------------------------------- 1 | package aws 2 | 3 | // JSONValue is a representation of a grab bag type that will be marshaled 4 | // into a json string. This type can be used just like any other map. 5 | // 6 | // Example: 7 | // 8 | // values := aws.JSONValue{ 9 | // "Foo": "Bar", 10 | // } 11 | // values["Baz"] = "Qux" 12 | type JSONValue map[string]interface{} 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go: -------------------------------------------------------------------------------- 1 | package request 2 | 3 | import ( 4 | "strings" 5 | ) 6 | 7 | func isErrConnectionReset(err error) bool { 8 | if strings.Contains(err.Error(), "read: connection reset") { 9 | return false 10 | } 11 | 12 | if strings.Contains(err.Error(), "use of closed network connection") || 13 | strings.Contains(err.Error(), "connection reset") || 14 | strings.Contains(err.Error(), "broken pipe") { 15 | return true 16 | } 17 | 18 | return false 19 | } 20 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/request/http_request.go: -------------------------------------------------------------------------------- 1 | package request 2 | 3 | import ( 4 | "io" 5 | "net/http" 6 | "net/url" 7 | ) 8 | 9 | func copyHTTPRequest(r *http.Request, body io.ReadCloser) *http.Request { 10 | req := new(http.Request) 11 | *req = *r 12 | req.URL = &url.URL{} 13 | *req.URL = *r.URL 14 | req.Body = body 15 | 16 | req.Header = http.Header{} 17 | for k, v := range r.Header { 18 | for _, vv := range v { 19 | req.Header.Add(k, vv) 20 | } 21 | } 22 | 23 | return req 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/request/request_context.go: -------------------------------------------------------------------------------- 1 | // +build go1.7 2 | 3 | package request 4 | 5 | import "github.com/aws/aws-sdk-go/aws" 6 | 7 | // setContext updates the Request to use the passed in context for cancellation. 8 | // Context will also be used for request retry delay. 9 | // 10 | // Creates shallow copy of the http.Request with the WithContext method. 11 | func setRequestContext(r *Request, ctx aws.Context) { 12 | r.context = ctx 13 | r.HTTPRequest = r.HTTPRequest.WithContext(ctx) 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/request/request_context_1_6.go: -------------------------------------------------------------------------------- 1 | // +build !go1.7 2 | 3 | package request 4 | 5 | import "github.com/aws/aws-sdk-go/aws" 6 | 7 | // setContext updates the Request to use the passed in context for cancellation. 8 | // Context will also be used for request retry delay. 9 | // 10 | // Creates shallow copy of the http.Request with the WithContext method. 11 | func setRequestContext(r *Request, ctx aws.Context) { 12 | r.context = ctx 13 | r.HTTPRequest.Cancel = ctx.Done() 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go: -------------------------------------------------------------------------------- 1 | // +build go1.7 2 | 3 | package session 4 | 5 | import ( 6 | "net" 7 | "net/http" 8 | "time" 9 | ) 10 | 11 | // Transport that should be used when a custom CA bundle is specified with the 12 | // SDK. 13 | func getCABundleTransport() *http.Transport { 14 | return &http.Transport{ 15 | Proxy: http.ProxyFromEnvironment, 16 | DialContext: (&net.Dialer{ 17 | Timeout: 30 * time.Second, 18 | KeepAlive: 30 * time.Second, 19 | DualStack: true, 20 | }).DialContext, 21 | MaxIdleConns: 100, 22 | IdleConnTimeout: 90 * time.Second, 23 | TLSHandshakeTimeout: 10 * time.Second, 24 | ExpectContinueTimeout: 1 * time.Second, 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go: -------------------------------------------------------------------------------- 1 | // +build !go1.6,go1.5 2 | 3 | package session 4 | 5 | import ( 6 | "net" 7 | "net/http" 8 | "time" 9 | ) 10 | 11 | // Transport that should be used when a custom CA bundle is specified with the 12 | // SDK. 13 | func getCABundleTransport() *http.Transport { 14 | return &http.Transport{ 15 | Proxy: http.ProxyFromEnvironment, 16 | Dial: (&net.Dialer{ 17 | Timeout: 30 * time.Second, 18 | KeepAlive: 30 * time.Second, 19 | }).Dial, 20 | TLSHandshakeTimeout: 10 * time.Second, 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go: -------------------------------------------------------------------------------- 1 | // +build !go1.7,go1.6 2 | 3 | package session 4 | 5 | import ( 6 | "net" 7 | "net/http" 8 | "time" 9 | ) 10 | 11 | // Transport that should be used when a custom CA bundle is specified with the 12 | // SDK. 13 | func getCABundleTransport() *http.Transport { 14 | return &http.Transport{ 15 | Proxy: http.ProxyFromEnvironment, 16 | Dial: (&net.Dialer{ 17 | Timeout: 30 * time.Second, 18 | KeepAlive: 30 * time.Second, 19 | }).Dial, 20 | TLSHandshakeTimeout: 10 * time.Second, 21 | ExpectContinueTimeout: 1 * time.Second, 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/options.go: -------------------------------------------------------------------------------- 1 | package v4 2 | 3 | // WithUnsignedPayload will enable and set the UnsignedPayload field to 4 | // true of the signer. 5 | func WithUnsignedPayload(v4 *Signer) { 6 | v4.UnsignedPayload = true 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.5.go: -------------------------------------------------------------------------------- 1 | // +build !go1.7 2 | 3 | package v4 4 | 5 | import ( 6 | "net/http" 7 | 8 | "github.com/aws/aws-sdk-go/aws" 9 | ) 10 | 11 | func requestContext(r *http.Request) aws.Context { 12 | return aws.BackgroundContext() 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.7.go: -------------------------------------------------------------------------------- 1 | // +build go1.7 2 | 3 | package v4 4 | 5 | import ( 6 | "net/http" 7 | 8 | "github.com/aws/aws-sdk-go/aws" 9 | ) 10 | 11 | func requestContext(r *http.Request) aws.Context { 12 | return r.Context() 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/uri_path.go: -------------------------------------------------------------------------------- 1 | // +build go1.5 2 | 3 | package v4 4 | 5 | import ( 6 | "net/url" 7 | "strings" 8 | ) 9 | 10 | func getURIPath(u *url.URL) string { 11 | var uri string 12 | 13 | if len(u.Opaque) > 0 { 14 | uri = "/" + strings.Join(strings.Split(u.Opaque, "/")[3:], "/") 15 | } else { 16 | uri = u.EscapedPath() 17 | } 18 | 19 | if len(uri) == 0 { 20 | uri = "/" 21 | } 22 | 23 | return uri 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/url.go: -------------------------------------------------------------------------------- 1 | // +build go1.8 2 | 3 | package aws 4 | 5 | import "net/url" 6 | 7 | // URLHostname will extract the Hostname without port from the URL value. 8 | // 9 | // Wrapper of net/url#URL.Hostname for backwards Go version compatibility. 10 | func URLHostname(url *url.URL) string { 11 | return url.Hostname() 12 | } 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/url_1_7.go: -------------------------------------------------------------------------------- 1 | // +build !go1.8 2 | 3 | package aws 4 | 5 | import ( 6 | "net/url" 7 | "strings" 8 | ) 9 | 10 | // URLHostname will extract the Hostname without port from the URL value. 11 | // 12 | // Copy of Go 1.8's net/url#URL.Hostname functionality. 13 | func URLHostname(url *url.URL) string { 14 | return stripPort(url.Host) 15 | 16 | } 17 | 18 | // stripPort is copy of Go 1.8 url#URL.Hostname functionality. 19 | // https://golang.org/src/net/url/url.go 20 | func stripPort(hostport string) string { 21 | colon := strings.IndexByte(hostport, ':') 22 | if colon == -1 { 23 | return hostport 24 | } 25 | if i := strings.IndexByte(hostport, ']'); i != -1 { 26 | return strings.TrimPrefix(hostport[:i], "[") 27 | } 28 | return hostport[:colon] 29 | } 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/aws/version.go: -------------------------------------------------------------------------------- 1 | // Package aws provides core functionality for making requests to AWS services. 2 | package aws 3 | 4 | // SDKName is the name of this AWS SDK 5 | const SDKName = "aws-sdk-go" 6 | 7 | // SDKVersion is the version of this SDK 8 | const SDKVersion = "1.36.0" 9 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/comma_token.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | var commaRunes = []rune(",") 4 | 5 | func isComma(b rune) bool { 6 | return b == ',' 7 | } 8 | 9 | func newCommaToken() Token { 10 | return newToken(TokenComma, commaRunes, NoneType) 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | // isComment will return whether or not the next byte(s) is a 4 | // comment. 5 | func isComment(b []rune) bool { 6 | if len(b) == 0 { 7 | return false 8 | } 9 | 10 | switch b[0] { 11 | case ';': 12 | return true 13 | case '#': 14 | return true 15 | } 16 | 17 | return false 18 | } 19 | 20 | // newCommentToken will create a comment token and 21 | // return how many bytes were read. 22 | func newCommentToken(b []rune) (Token, int, error) { 23 | i := 0 24 | for ; i < len(b); i++ { 25 | if b[i] == '\n' { 26 | break 27 | } 28 | 29 | if len(b)-i > 2 && b[i] == '\r' && b[i+1] == '\n' { 30 | break 31 | } 32 | } 33 | 34 | return newToken(TokenComment, b[:i], NoneType), i, nil 35 | } 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go: -------------------------------------------------------------------------------- 1 | // Package ini is an LL(1) parser for configuration files. 2 | // 3 | // Example: 4 | // sections, err := ini.OpenFile("/path/to/file") 5 | // if err != nil { 6 | // panic(err) 7 | // } 8 | // 9 | // profile := "foo" 10 | // section, ok := sections.GetSection(profile) 11 | // if !ok { 12 | // fmt.Printf("section %q could not be found", profile) 13 | // } 14 | // 15 | // Below is the BNF that describes this parser 16 | // Grammar: 17 | // stmt -> value stmt' 18 | // stmt' -> epsilon | op stmt 19 | // value -> number | string | boolean | quoted_string 20 | // 21 | // section -> [ section' 22 | // section' -> value section_close 23 | // section_close -> ] 24 | // 25 | // SkipState will skip (NL WS)+ 26 | // 27 | // comment -> # comment' | ; comment' 28 | // comment' -> epsilon | value 29 | package ini 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/empty_token.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | // emptyToken is used to satisfy the Token interface 4 | var emptyToken = newToken(TokenNone, []rune{}, NoneType) 5 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/expression.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | // newExpression will return an expression AST. 4 | // Expr represents an expression 5 | // 6 | // grammar: 7 | // expr -> string | number 8 | func newExpression(tok Token) AST { 9 | return newASTWithRootToken(ASTKindExpr, tok) 10 | } 11 | 12 | func newEqualExpr(left AST, tok Token) AST { 13 | return newASTWithRootToken(ASTKindEqualExpr, tok, left) 14 | } 15 | 16 | // EqualExprKey will return a LHS value in the equal expr 17 | func EqualExprKey(ast AST) string { 18 | children := ast.GetChildren() 19 | if len(children) == 0 || ast.Kind != ASTKindEqualExpr { 20 | return "" 21 | } 22 | 23 | return string(children[0].Root.Raw()) 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go: -------------------------------------------------------------------------------- 1 | // +build gofuzz 2 | 3 | package ini 4 | 5 | import ( 6 | "bytes" 7 | ) 8 | 9 | func Fuzz(data []byte) int { 10 | b := bytes.NewReader(data) 11 | 12 | if _, err := Parse(b); err != nil { 13 | return 0 14 | } 15 | 16 | return 1 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/newline_token.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | func isNewline(b []rune) bool { 4 | if len(b) == 0 { 5 | return false 6 | } 7 | 8 | if b[0] == '\n' { 9 | return true 10 | } 11 | 12 | if len(b) < 2 { 13 | return false 14 | } 15 | 16 | return b[0] == '\r' && b[1] == '\n' 17 | } 18 | 19 | func newNewlineToken(b []rune) (Token, int, error) { 20 | i := 1 21 | if b[0] == '\r' && isNewline(b[1:]) { 22 | i++ 23 | } 24 | 25 | if !isNewline([]rune(b[:i])) { 26 | return emptyToken, 0, NewParseError("invalid new line token") 27 | } 28 | 29 | return newToken(TokenNL, b[:i], NoneType), i, nil 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/op_tokens.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | import ( 4 | "fmt" 5 | ) 6 | 7 | var ( 8 | equalOp = []rune("=") 9 | equalColonOp = []rune(":") 10 | ) 11 | 12 | func isOp(b []rune) bool { 13 | if len(b) == 0 { 14 | return false 15 | } 16 | 17 | switch b[0] { 18 | case '=': 19 | return true 20 | case ':': 21 | return true 22 | default: 23 | return false 24 | } 25 | } 26 | 27 | func newOpToken(b []rune) (Token, int, error) { 28 | tok := Token{} 29 | 30 | switch b[0] { 31 | case '=': 32 | tok = newToken(TokenOp, equalOp, NoneType) 33 | case ':': 34 | tok = newToken(TokenOp, equalColonOp, NoneType) 35 | default: 36 | return tok, 0, NewParseError(fmt.Sprintf("unexpected op type, %v", b[0])) 37 | } 38 | return tok, 1, nil 39 | } 40 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/sep_tokens.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | import ( 4 | "fmt" 5 | ) 6 | 7 | var ( 8 | emptyRunes = []rune{} 9 | ) 10 | 11 | func isSep(b []rune) bool { 12 | if len(b) == 0 { 13 | return false 14 | } 15 | 16 | switch b[0] { 17 | case '[', ']': 18 | return true 19 | default: 20 | return false 21 | } 22 | } 23 | 24 | var ( 25 | openBrace = []rune("[") 26 | closeBrace = []rune("]") 27 | ) 28 | 29 | func newSepToken(b []rune) (Token, int, error) { 30 | tok := Token{} 31 | 32 | switch b[0] { 33 | case '[': 34 | tok = newToken(TokenSep, openBrace, NoneType) 35 | case ']': 36 | tok = newToken(TokenSep, closeBrace, NoneType) 37 | default: 38 | return tok, 0, NewParseError(fmt.Sprintf("unexpected sep type, %v", b[0])) 39 | } 40 | return tok, 1, nil 41 | } 42 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/walker.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | // Walk will traverse the AST using the v, the Visitor. 4 | func Walk(tree []AST, v Visitor) error { 5 | for _, node := range tree { 6 | switch node.Kind { 7 | case ASTKindExpr, 8 | ASTKindExprStatement: 9 | 10 | if err := v.VisitExpr(node); err != nil { 11 | return err 12 | } 13 | case ASTKindStatement, 14 | ASTKindCompletedSectionStatement, 15 | ASTKindNestedSectionStatement, 16 | ASTKindCompletedNestedSectionStatement: 17 | 18 | if err := v.VisitStatement(node); err != nil { 19 | return err 20 | } 21 | } 22 | } 23 | 24 | return nil 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/ini/ws_token.go: -------------------------------------------------------------------------------- 1 | package ini 2 | 3 | import ( 4 | "unicode" 5 | ) 6 | 7 | // isWhitespace will return whether or not the character is 8 | // a whitespace character. 9 | // 10 | // Whitespace is defined as a space or tab. 11 | func isWhitespace(c rune) bool { 12 | return unicode.IsSpace(c) && c != '\n' && c != '\r' 13 | } 14 | 15 | func newWSToken(b []rune) (Token, int, error) { 16 | i := 0 17 | for ; i < len(b); i++ { 18 | if !isWhitespace(b[i]) { 19 | break 20 | } 21 | } 22 | 23 | return newToken(TokenWS, b[:i], NoneType), i, nil 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkio/byte.go: -------------------------------------------------------------------------------- 1 | package sdkio 2 | 3 | const ( 4 | // Byte is 8 bits 5 | Byte int64 = 1 6 | // KibiByte (KiB) is 1024 Bytes 7 | KibiByte = Byte * 1024 8 | // MebiByte (MiB) is 1024 KiB 9 | MebiByte = KibiByte * 1024 10 | // GibiByte (GiB) is 1024 MiB 11 | GibiByte = MebiByte * 1024 12 | ) 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go: -------------------------------------------------------------------------------- 1 | // +build !go1.7 2 | 3 | package sdkio 4 | 5 | // Copy of Go 1.7 io package's Seeker constants. 6 | const ( 7 | SeekStart = 0 // seek relative to the origin of the file 8 | SeekCurrent = 1 // seek relative to the current offset 9 | SeekEnd = 2 // seek relative to the end 10 | ) 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go: -------------------------------------------------------------------------------- 1 | // +build go1.7 2 | 3 | package sdkio 4 | 5 | import "io" 6 | 7 | // Alias for Go 1.7 io package Seeker constants 8 | const ( 9 | SeekStart = io.SeekStart // seek relative to the origin of the file 10 | SeekCurrent = io.SeekCurrent // seek relative to the current offset 11 | SeekEnd = io.SeekEnd // seek relative to the end 12 | ) 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor.go: -------------------------------------------------------------------------------- 1 | // +build go1.10 2 | 3 | package sdkmath 4 | 5 | import "math" 6 | 7 | // Round returns the nearest integer, rounding half away from zero. 8 | // 9 | // Special cases are: 10 | // Round(±0) = ±0 11 | // Round(±Inf) = ±Inf 12 | // Round(NaN) = NaN 13 | func Round(x float64) float64 { 14 | return math.Round(x) 15 | } 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go: -------------------------------------------------------------------------------- 1 | package sdkrand 2 | 3 | import ( 4 | "math/rand" 5 | "sync" 6 | "time" 7 | ) 8 | 9 | // lockedSource is a thread-safe implementation of rand.Source 10 | type lockedSource struct { 11 | lk sync.Mutex 12 | src rand.Source 13 | } 14 | 15 | func (r *lockedSource) Int63() (n int64) { 16 | r.lk.Lock() 17 | n = r.src.Int63() 18 | r.lk.Unlock() 19 | return 20 | } 21 | 22 | func (r *lockedSource) Seed(seed int64) { 23 | r.lk.Lock() 24 | r.src.Seed(seed) 25 | r.lk.Unlock() 26 | } 27 | 28 | // SeededRand is a new RNG using a thread safe implementation of rand.Source 29 | var SeededRand = rand.New(&lockedSource{src: rand.NewSource(time.Now().UnixNano())}) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read.go: -------------------------------------------------------------------------------- 1 | // +build go1.6 2 | 3 | package sdkrand 4 | 5 | import "math/rand" 6 | 7 | // Read provides the stub for math.Rand.Read method support for go version's 8 | // 1.6 and greater. 9 | func Read(r *rand.Rand, p []byte) (int, error) { 10 | return r.Read(p) 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read_1_5.go: -------------------------------------------------------------------------------- 1 | // +build !go1.6 2 | 3 | package sdkrand 4 | 5 | import "math/rand" 6 | 7 | // Read backfills Go 1.6's math.Rand.Reader for Go 1.5 8 | func Read(r *rand.Rand, p []byte) (n int, err error) { 9 | // Copy of Go standard libraries math package's read function not added to 10 | // standard library until Go 1.6. 11 | var pos int8 12 | var val int64 13 | for n = 0; n < len(p); n++ { 14 | if pos == 0 { 15 | val = r.Int63() 16 | pos = 7 17 | } 18 | p[n] = byte(val) 19 | val >>= 8 20 | pos-- 21 | } 22 | 23 | return n, err 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/sdkuri/path.go: -------------------------------------------------------------------------------- 1 | package sdkuri 2 | 3 | import ( 4 | "path" 5 | "strings" 6 | ) 7 | 8 | // PathJoin will join the elements of the path delimited by the "/" 9 | // character. Similar to path.Join with the exception the trailing "/" 10 | // character is preserved if present. 11 | func PathJoin(elems ...string) string { 12 | if len(elems) == 0 { 13 | return "" 14 | } 15 | 16 | hasTrailing := strings.HasSuffix(elems[len(elems)-1], "/") 17 | str := path.Join(elems...) 18 | if hasTrailing && str != "/" { 19 | str += "/" 20 | } 21 | 22 | return str 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go: -------------------------------------------------------------------------------- 1 | package shareddefaults 2 | 3 | const ( 4 | // ECSCredsProviderEnvVar is an environmental variable key used to 5 | // determine which path needs to be hit. 6 | ECSCredsProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_RELATIVE_URI" 7 | ) 8 | 9 | // ECSContainerCredentialsURI is the endpoint to retrieve container 10 | // credentials. This can be overridden to test to ensure the credential process 11 | // is behaving correctly. 12 | var ECSContainerCredentialsURI = "http://169.254.170.2" 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/internal/strings/strings.go: -------------------------------------------------------------------------------- 1 | package strings 2 | 3 | import ( 4 | "strings" 5 | ) 6 | 7 | // HasPrefixFold tests whether the string s begins with prefix, interpreted as UTF-8 strings, 8 | // under Unicode case-folding. 9 | func HasPrefixFold(s, prefix string) bool { 10 | return len(s) >= len(prefix) && strings.EqualFold(s[0:len(prefix)], prefix) 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/error.go: -------------------------------------------------------------------------------- 1 | package eventstream 2 | 3 | import "fmt" 4 | 5 | // LengthError provides the error for items being larger than a maximum length. 6 | type LengthError struct { 7 | Part string 8 | Want int 9 | Have int 10 | Value interface{} 11 | } 12 | 13 | func (e LengthError) Error() string { 14 | return fmt.Sprintf("%s length invalid, %d/%d, %v", 15 | e.Part, e.Want, e.Have, e.Value) 16 | } 17 | 18 | // ChecksumError provides the error for message checksum invalidation errors. 19 | type ChecksumError struct{} 20 | 21 | func (e ChecksumError) Error() string { 22 | return "message checksum mismatch" 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/eventstreamapi/shared.go: -------------------------------------------------------------------------------- 1 | package eventstreamapi 2 | 3 | // EventStream headers with specific meaning to async API functionality. 4 | const ( 5 | ChunkSignatureHeader = `:chunk-signature` // chunk signature for message 6 | DateHeader = `:date` // Date header for signature 7 | 8 | // Message header and values 9 | MessageTypeHeader = `:message-type` // Identifies type of message. 10 | EventMessageType = `event` 11 | ErrorMessageType = `error` 12 | ExceptionMessageType = `exception` 13 | 14 | // Message Events 15 | EventTypeHeader = `:event-type` // Identifies message event type e.g. "Stats". 16 | 17 | // Message Error 18 | ErrorCodeHeader = `:error-code` 19 | ErrorMessageHeader = `:error-message` 20 | 21 | // Message Exception 22 | ExceptionTypeHeader = `:exception-type` 23 | ) 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal.go: -------------------------------------------------------------------------------- 1 | package protocol 2 | 3 | import ( 4 | "io" 5 | "io/ioutil" 6 | 7 | "github.com/aws/aws-sdk-go/aws/request" 8 | ) 9 | 10 | // UnmarshalDiscardBodyHandler is a named request handler to empty and close a response's body 11 | var UnmarshalDiscardBodyHandler = request.NamedHandler{Name: "awssdk.shared.UnmarshalDiscardBody", Fn: UnmarshalDiscardBody} 12 | 13 | // UnmarshalDiscardBody is a request handler to empty a response's body and closing it. 14 | func UnmarshalDiscardBody(r *request.Request) { 15 | if r.HTTPResponse == nil || r.HTTPResponse.Body == nil { 16 | return 17 | } 18 | 19 | io.Copy(ioutil.Discard, r.HTTPResponse.Body) 20 | r.HTTPResponse.Body.Close() 21 | } 22 | 23 | // ResponseMetadata provides the SDK response metadata attributes. 24 | type ResponseMetadata struct { 25 | StatusCode int 26 | RequestID string 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/sort.go: -------------------------------------------------------------------------------- 1 | package xmlutil 2 | 3 | import ( 4 | "encoding/xml" 5 | "strings" 6 | ) 7 | 8 | type xmlAttrSlice []xml.Attr 9 | 10 | func (x xmlAttrSlice) Len() int { 11 | return len(x) 12 | } 13 | 14 | func (x xmlAttrSlice) Less(i, j int) bool { 15 | spaceI, spaceJ := x[i].Name.Space, x[j].Name.Space 16 | localI, localJ := x[i].Name.Local, x[j].Name.Local 17 | valueI, valueJ := x[i].Value, x[j].Value 18 | 19 | spaceCmp := strings.Compare(spaceI, spaceJ) 20 | localCmp := strings.Compare(localI, localJ) 21 | valueCmp := strings.Compare(valueI, valueJ) 22 | 23 | if spaceCmp == -1 || (spaceCmp == 0 && (localCmp == -1 || (localCmp == 0 && valueCmp == -1))) { 24 | return true 25 | } 26 | 27 | return false 28 | } 29 | 30 | func (x xmlAttrSlice) Swap(i, j int) { 31 | x[i], x[j] = x[j], x[i] 32 | } 33 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/platform_handlers.go: -------------------------------------------------------------------------------- 1 | // +build !go1.6 2 | 3 | package s3 4 | 5 | import "github.com/aws/aws-sdk-go/aws/request" 6 | 7 | func platformRequestHandlers(r *request.Request) { 8 | } 9 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/platform_handlers_go1.6.go: -------------------------------------------------------------------------------- 1 | // +build go1.6 2 | 3 | package s3 4 | 5 | import ( 6 | "github.com/aws/aws-sdk-go/aws" 7 | "github.com/aws/aws-sdk-go/aws/request" 8 | ) 9 | 10 | func platformRequestHandlers(r *request.Request) { 11 | if r.Operation.HTTPMethod == "PUT" { 12 | // 100-Continue should only be used on put requests. 13 | r.Handlers.Sign.PushBack(add100Continue) 14 | } 15 | } 16 | 17 | func add100Continue(r *request.Request) { 18 | if aws.BoolValue(r.Config.S3Disable100Continue) { 19 | return 20 | } 21 | if r.HTTPRequest.ContentLength < 1024*1024*2 { 22 | // Ignore requests smaller than 2MB. This helps prevent delaying 23 | // requests unnecessarily. 24 | return 25 | } 26 | 27 | r.HTTPRequest.Header.Set("Expect", "100-Continue") 28 | } 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/s3manager/default_read_seeker_write_to.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package s3manager 4 | 5 | func defaultUploadBufferProvider() ReadSeekerWriteToProvider { 6 | return nil 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/s3manager/default_read_seeker_write_to_windows.go: -------------------------------------------------------------------------------- 1 | package s3manager 2 | 3 | func defaultUploadBufferProvider() ReadSeekerWriteToProvider { 4 | return NewBufferedReadSeekerWriteToPool(1024 * 1024) 5 | } 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/s3manager/default_writer_read_from.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package s3manager 4 | 5 | func defaultDownloadBufferProvider() WriterReadFromProvider { 6 | return nil 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/s3manager/default_writer_read_from_windows.go: -------------------------------------------------------------------------------- 1 | package s3manager 2 | 3 | func defaultDownloadBufferProvider() WriterReadFromProvider { 4 | return NewPooledBufferedWriterReadFromProvider(1024 * 1024) 5 | } 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/s3/s3manager/doc.go: -------------------------------------------------------------------------------- 1 | // Package s3manager provides utilities to upload and download objects from 2 | // S3 concurrently. Helpful for when working with large objects. 3 | package s3manager 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go: -------------------------------------------------------------------------------- 1 | package sts 2 | 3 | import "github.com/aws/aws-sdk-go/aws/request" 4 | 5 | func init() { 6 | initRequest = customizeRequest 7 | } 8 | 9 | func customizeRequest(r *request.Request) { 10 | r.RetryErrorCodes = append(r.RetryErrorCodes, ErrCodeIDPCommunicationErrorException) 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/cihub/seelog/internals_baseerror.go: -------------------------------------------------------------------------------- 1 | package seelog 2 | 3 | // Base struct for custom errors. 4 | type baseError struct { 5 | message string 6 | } 7 | 8 | func (be baseError) Error() string { 9 | return be.message 10 | } 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/coreos/go-systemd/NOTICE: -------------------------------------------------------------------------------- 1 | CoreOS Project 2 | Copyright 2018 CoreOS, Inc 3 | 4 | This product includes software developed at CoreOS, Inc. 5 | (http://www.coreos.com/). 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/davecgh/go-spew/LICENSE: -------------------------------------------------------------------------------- 1 | ISC License 2 | 3 | Copyright (c) 2012-2016 Dave Collins 4 | 5 | Permission to use, copy, modify, and/or distribute this software for any 6 | purpose with or without fee is hereby granted, provided that the above 7 | copyright notice and this permission notice appear in all copies. 8 | 9 | THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10 | WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 | MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12 | ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 | WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 | ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15 | OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/NOTICE: -------------------------------------------------------------------------------- 1 | Docker 2 | Copyright 2012-2017 Docker, Inc. 3 | 4 | This product includes software developed at Docker, Inc. (https://www.docker.com). 5 | 6 | This product contains software (https://github.com/kr/pty) developed 7 | by Keith Rarick, licensed under the MIT License. 8 | 9 | The following is courtesy of our legal counsel: 10 | 11 | 12 | Use and transfer of Docker may be subject to certain restrictions by the 13 | United States and other governments. 14 | It is your responsibility to ensure that your use and/or transfer does not 15 | violate applicable laws. 16 | 17 | For more information, please see https://www.bis.doc.gov 18 | 19 | See also https://www.apache.org/dev/crypto.html and/or seek legal counsel. 20 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/auth.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // AuthConfig contains authorization information for connecting to a Registry 4 | type AuthConfig struct { 5 | Username string `json:"username,omitempty"` 6 | Password string `json:"password,omitempty"` 7 | Auth string `json:"auth,omitempty"` 8 | 9 | // Email is an optional value associated with the username. 10 | // This field is deprecated and will be removed in a later 11 | // version of docker. 12 | Email string `json:"email,omitempty"` 13 | 14 | ServerAddress string `json:"serveraddress,omitempty"` 15 | 16 | // IdentityToken is used to authenticate the user and get 17 | // an access token for the registry. 18 | IdentityToken string `json:"identitytoken,omitempty"` 19 | 20 | // RegistryToken is a bearer token to be sent to a registry 21 | RegistryToken string `json:"registrytoken,omitempty"` 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/blkiodev/blkio.go: -------------------------------------------------------------------------------- 1 | package blkiodev 2 | 3 | import "fmt" 4 | 5 | // WeightDevice is a structure that holds device:weight pair 6 | type WeightDevice struct { 7 | Path string 8 | Weight uint16 9 | } 10 | 11 | func (w *WeightDevice) String() string { 12 | return fmt.Sprintf("%s:%d", w.Path, w.Weight) 13 | } 14 | 15 | // ThrottleDevice is a structure that holds device:rate_per_second pair 16 | type ThrottleDevice struct { 17 | Path string 18 | Rate uint64 19 | } 20 | 21 | func (t *ThrottleDevice) String() string { 22 | return fmt.Sprintf("%s:%d", t.Path, t.Rate) 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/container/container_changes.go: -------------------------------------------------------------------------------- 1 | package container 2 | 3 | // ---------------------------------------------------------------------------- 4 | // DO NOT EDIT THIS FILE 5 | // This file was generated by `swagger generate operation` 6 | // 7 | // See hack/generate-swagger-api.sh 8 | // ---------------------------------------------------------------------------- 9 | 10 | // ContainerChangeResponseItem container change response item 11 | // swagger:model ContainerChangeResponseItem 12 | type ContainerChangeResponseItem struct { 13 | 14 | // Kind of change 15 | // Required: true 16 | Kind uint8 `json:"Kind"` 17 | 18 | // Path to file that has changed 19 | // Required: true 20 | Path string `json:"Path"` 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/container/container_create.go: -------------------------------------------------------------------------------- 1 | package container 2 | 3 | // ---------------------------------------------------------------------------- 4 | // DO NOT EDIT THIS FILE 5 | // This file was generated by `swagger generate operation` 6 | // 7 | // See hack/generate-swagger-api.sh 8 | // ---------------------------------------------------------------------------- 9 | 10 | // ContainerCreateCreatedBody container create created body 11 | // swagger:model ContainerCreateCreatedBody 12 | type ContainerCreateCreatedBody struct { 13 | 14 | // The ID of the created container 15 | // Required: true 16 | ID string `json:"Id"` 17 | 18 | // Warnings encountered when creating the container 19 | // Required: true 20 | Warnings []string `json:"Warnings"` 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/container/container_top.go: -------------------------------------------------------------------------------- 1 | package container 2 | 3 | // ---------------------------------------------------------------------------- 4 | // DO NOT EDIT THIS FILE 5 | // This file was generated by `swagger generate operation` 6 | // 7 | // See hack/generate-swagger-api.sh 8 | // ---------------------------------------------------------------------------- 9 | 10 | // ContainerTopOKBody container top o k body 11 | // swagger:model ContainerTopOKBody 12 | type ContainerTopOKBody struct { 13 | 14 | // Each process running in the container, where each is process is an array of values corresponding to the titles 15 | // Required: true 16 | Processes [][]string `json:"Processes"` 17 | 18 | // The ps column titles 19 | // Required: true 20 | Titles []string `json:"Titles"` 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/container/container_update.go: -------------------------------------------------------------------------------- 1 | package container 2 | 3 | // ---------------------------------------------------------------------------- 4 | // DO NOT EDIT THIS FILE 5 | // This file was generated by `swagger generate operation` 6 | // 7 | // See hack/generate-swagger-api.sh 8 | // ---------------------------------------------------------------------------- 9 | 10 | // ContainerUpdateOKBody container update o k body 11 | // swagger:model ContainerUpdateOKBody 12 | type ContainerUpdateOKBody struct { 13 | 14 | // warnings 15 | // Required: true 16 | Warnings []string `json:"Warnings"` 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/container/container_wait.go: -------------------------------------------------------------------------------- 1 | package container 2 | 3 | // ---------------------------------------------------------------------------- 4 | // DO NOT EDIT THIS FILE 5 | // This file was generated by `swagger generate operation` 6 | // 7 | // See hack/generate-swagger-api.sh 8 | // ---------------------------------------------------------------------------- 9 | 10 | // ContainerWaitOKBody container wait o k body 11 | // swagger:model ContainerWaitOKBody 12 | type ContainerWaitOKBody struct { 13 | 14 | // Exit code of the container 15 | // Required: true 16 | StatusCode int64 `json:"StatusCode"` 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/container/waitcondition.go: -------------------------------------------------------------------------------- 1 | package container 2 | 3 | // WaitCondition is a type used to specify a container state for which 4 | // to wait. 5 | type WaitCondition string 6 | 7 | // Possible WaitCondition Values. 8 | // 9 | // WaitConditionNotRunning (default) is used to wait for any of the non-running 10 | // states: "created", "exited", "dead", "removing", or "removed". 11 | // 12 | // WaitConditionNextExit is used to wait for the next time the state changes 13 | // to a non-running state. If the state is currently "created" or "exited", 14 | // this would cause Wait() to block until either the container runs and exits 15 | // or is removed. 16 | // 17 | // WaitConditionRemoved is used to wait for the container to be removed. 18 | const ( 19 | WaitConditionNotRunning WaitCondition = "not-running" 20 | WaitConditionNextExit WaitCondition = "next-exit" 21 | WaitConditionRemoved WaitCondition = "removed" 22 | ) 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/error_response.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // ErrorResponse Represents an error. 7 | // swagger:model ErrorResponse 8 | type ErrorResponse struct { 9 | 10 | // The error message. 11 | // Required: true 12 | Message string `json:"message"` 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/graph_driver_data.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // GraphDriverData Information about a container's graph driver. 7 | // swagger:model GraphDriverData 8 | type GraphDriverData struct { 9 | 10 | // data 11 | // Required: true 12 | Data map[string]string `json:"Data"` 13 | 14 | // name 15 | // Required: true 16 | Name string `json:"Name"` 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/id_response.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // IDResponse Response to an API call that returns just an Id 7 | // swagger:model IdResponse 8 | type IDResponse struct { 9 | 10 | // The id of the newly created object. 11 | // Required: true 12 | ID string `json:"Id"` 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/image_delete_response_item.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // ImageDeleteResponseItem image delete response item 7 | // swagger:model ImageDeleteResponseItem 8 | type ImageDeleteResponseItem struct { 9 | 10 | // The image ID of an image that was deleted 11 | Deleted string `json:"Deleted,omitempty"` 12 | 13 | // The image ID of an image that was untagged 14 | Untagged string `json:"Untagged,omitempty"` 15 | } 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/plugin_device.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // PluginDevice plugin device 7 | // swagger:model PluginDevice 8 | type PluginDevice struct { 9 | 10 | // description 11 | // Required: true 12 | Description string `json:"Description"` 13 | 14 | // name 15 | // Required: true 16 | Name string `json:"Name"` 17 | 18 | // path 19 | // Required: true 20 | Path *string `json:"Path"` 21 | 22 | // settable 23 | // Required: true 24 | Settable []string `json:"Settable"` 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/plugin_env.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // PluginEnv plugin env 7 | // swagger:model PluginEnv 8 | type PluginEnv struct { 9 | 10 | // description 11 | // Required: true 12 | Description string `json:"Description"` 13 | 14 | // name 15 | // Required: true 16 | Name string `json:"Name"` 17 | 18 | // settable 19 | // Required: true 20 | Settable []string `json:"Settable"` 21 | 22 | // value 23 | // Required: true 24 | Value *string `json:"Value"` 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/plugin_interface_type.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // PluginInterfaceType plugin interface type 7 | // swagger:model PluginInterfaceType 8 | type PluginInterfaceType struct { 9 | 10 | // capability 11 | // Required: true 12 | Capability string `json:"Capability"` 13 | 14 | // prefix 15 | // Required: true 16 | Prefix string `json:"Prefix"` 17 | 18 | // version 19 | // Required: true 20 | Version string `json:"Version"` 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/plugin_mount.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // PluginMount plugin mount 7 | // swagger:model PluginMount 8 | type PluginMount struct { 9 | 10 | // description 11 | // Required: true 12 | Description string `json:"Description"` 13 | 14 | // destination 15 | // Required: true 16 | Destination string `json:"Destination"` 17 | 18 | // name 19 | // Required: true 20 | Name string `json:"Name"` 21 | 22 | // options 23 | // Required: true 24 | Options []string `json:"Options"` 25 | 26 | // settable 27 | // Required: true 28 | Settable []string `json:"Settable"` 29 | 30 | // source 31 | // Required: true 32 | Source *string `json:"Source"` 33 | 34 | // type 35 | // Required: true 36 | Type string `json:"Type"` 37 | } 38 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/port.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // Port An open port on a container 7 | // swagger:model Port 8 | type Port struct { 9 | 10 | // IP 11 | IP string `json:"IP,omitempty"` 12 | 13 | // Port on the container 14 | // Required: true 15 | PrivatePort uint16 `json:"PrivatePort"` 16 | 17 | // Port exposed on the host 18 | PublicPort uint16 `json:"PublicPort,omitempty"` 19 | 20 | // type 21 | // Required: true 22 | Type string `json:"Type"` 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/registry/authenticate.go: -------------------------------------------------------------------------------- 1 | package registry 2 | 3 | // ---------------------------------------------------------------------------- 4 | // DO NOT EDIT THIS FILE 5 | // This file was generated by `swagger generate operation` 6 | // 7 | // See hack/generate-swagger-api.sh 8 | // ---------------------------------------------------------------------------- 9 | 10 | // AuthenticateOKBody authenticate o k body 11 | // swagger:model AuthenticateOKBody 12 | type AuthenticateOKBody struct { 13 | 14 | // An opaque token used to authenticate a user after a successful login 15 | // Required: true 16 | IdentityToken string `json:"IdentityToken"` 17 | 18 | // The status of the authentication 19 | // Required: true 20 | Status string `json:"Status"` 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/service_update_response.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // This file was generated by the swagger tool. 4 | // Editing this file might prove futile when you re-run the swagger generate command 5 | 6 | // ServiceUpdateResponse service update response 7 | // swagger:model ServiceUpdateResponse 8 | type ServiceUpdateResponse struct { 9 | 10 | // Optional warning messages 11 | Warnings []string `json:"Warnings"` 12 | } 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/strslice/strslice.go: -------------------------------------------------------------------------------- 1 | package strslice 2 | 3 | import "encoding/json" 4 | 5 | // StrSlice represents a string or an array of strings. 6 | // We need to override the json decoder to accept both options. 7 | type StrSlice []string 8 | 9 | // UnmarshalJSON decodes the byte slice whether it's a string or an array of 10 | // strings. This method is needed to implement json.Unmarshaler. 11 | func (e *StrSlice) UnmarshalJSON(b []byte) error { 12 | if len(b) == 0 { 13 | // With no input, we preserve the existing value by returning nil and 14 | // leaving the target alone. This allows defining default values for 15 | // the type. 16 | return nil 17 | } 18 | 19 | p := make([]string, 0, 1) 20 | if err := json.Unmarshal(b, &p); err != nil { 21 | var s string 22 | if err := json.Unmarshal(b, &s); err != nil { 23 | return err 24 | } 25 | p = append(p, s) 26 | } 27 | 28 | *e = p 29 | return nil 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/swarm/config.go: -------------------------------------------------------------------------------- 1 | package swarm 2 | 3 | import "os" 4 | 5 | // Config represents a config. 6 | type Config struct { 7 | ID string 8 | Meta 9 | Spec ConfigSpec 10 | } 11 | 12 | // ConfigSpec represents a config specification from a config in swarm 13 | type ConfigSpec struct { 14 | Annotations 15 | Data []byte `json:",omitempty"` 16 | } 17 | 18 | // ConfigReferenceFileTarget is a file target in a config reference 19 | type ConfigReferenceFileTarget struct { 20 | Name string 21 | UID string 22 | GID string 23 | Mode os.FileMode 24 | } 25 | 26 | // ConfigReference is a reference to a config in swarm 27 | type ConfigReference struct { 28 | File *ConfigReferenceFileTarget 29 | ConfigID string 30 | ConfigName string 31 | } 32 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/swarm/runtime.go: -------------------------------------------------------------------------------- 1 | package swarm 2 | 3 | // RuntimeType is the type of runtime used for the TaskSpec 4 | type RuntimeType string 5 | 6 | // RuntimeURL is the proto type url 7 | type RuntimeURL string 8 | 9 | const ( 10 | // RuntimeContainer is the container based runtime 11 | RuntimeContainer RuntimeType = "container" 12 | // RuntimePlugin is the plugin based runtime 13 | RuntimePlugin RuntimeType = "plugin" 14 | 15 | // RuntimeURLContainer is the proto url for the container type 16 | RuntimeURLContainer RuntimeURL = "types.docker.com/RuntimeContainer" 17 | // RuntimeURLPlugin is the proto url for the plugin type 18 | RuntimeURLPlugin RuntimeURL = "types.docker.com/RuntimePlugin" 19 | ) 20 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/api/types/swarm/secret.go: -------------------------------------------------------------------------------- 1 | package swarm 2 | 3 | import "os" 4 | 5 | // Secret represents a secret. 6 | type Secret struct { 7 | ID string 8 | Meta 9 | Spec SecretSpec 10 | } 11 | 12 | // SecretSpec represents a secret specification from a secret in swarm 13 | type SecretSpec struct { 14 | Annotations 15 | Data []byte `json:",omitempty"` 16 | } 17 | 18 | // SecretReferenceFileTarget is a file target in a secret reference 19 | type SecretReferenceFileTarget struct { 20 | Name string 21 | UID string 22 | GID string 23 | Mode os.FileMode 24 | } 25 | 26 | // SecretReference is a reference to a secret in swarm 27 | type SecretReference struct { 28 | File *SecretReferenceFileTarget 29 | SecretID string 30 | SecretName string 31 | } 32 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/docs/static_files/contributors.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aws/amazon-ecs-init/9332428bb18f16788bc6a905c61c17736937f6b8/ecs-init/vendor/github.com/docker/docker/docs/static_files/contributors.png -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/hack/generate-authors.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | set -e 3 | 4 | cd "$(dirname "$(readlink -f "$BASH_SOURCE")")/.." 5 | 6 | # see also ".mailmap" for how email addresses and names are deduplicated 7 | 8 | { 9 | cat <<-'EOH' 10 | # This file lists all individuals having contributed content to the repository. 11 | # For how it is generated, see `hack/generate-authors.sh`. 12 | EOH 13 | echo 14 | git log --format='%aN <%aE>' | LC_ALL=C.UTF-8 sort -uf 15 | } > AUTHORS 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/hack/make/.build-deb/docker-engine.docker.default: -------------------------------------------------------------------------------- 1 | ../../../contrib/init/sysvinit-debian/docker.default -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/hack/make/.build-deb/docker-engine.docker.init: -------------------------------------------------------------------------------- 1 | ../../../contrib/init/sysvinit-debian/docker -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/hack/make/.build-deb/docker-engine.docker.upstart: -------------------------------------------------------------------------------- 1 | ../../../contrib/init/upstart/docker.conf -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/hack/make/.build-deb/docker-engine.udev: -------------------------------------------------------------------------------- 1 | ../../../contrib/udev/80-docker.rules -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/opts/hosts_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package opts 4 | 5 | import "fmt" 6 | 7 | // DefaultHost constant defines the default host string used by docker on other hosts than Windows 8 | var DefaultHost = fmt.Sprintf("unix://%s", DefaultUnixSocket) 9 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/opts/hosts_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package opts 4 | 5 | // DefaultHost constant defines the default host string used by docker on Windows 6 | var DefaultHost = "npipe://" + DefaultNamedPipe 7 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/opts/opts_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package opts 4 | 5 | // DefaultHTTPHost Default HTTP Host used if only port is provided to -H flag e.g. dockerd -H tcp://:8080 6 | const DefaultHTTPHost = "localhost" 7 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/opts/quotedstring.go: -------------------------------------------------------------------------------- 1 | package opts 2 | 3 | // QuotedString is a string that may have extra quotes around the value. The 4 | // quotes are stripped from the value. 5 | type QuotedString struct { 6 | value *string 7 | } 8 | 9 | // Set sets a new value 10 | func (s *QuotedString) Set(val string) error { 11 | *s.value = trimQuotes(val) 12 | return nil 13 | } 14 | 15 | // Type returns the type of the value 16 | func (s *QuotedString) Type() string { 17 | return "string" 18 | } 19 | 20 | func (s *QuotedString) String() string { 21 | return string(*s.value) 22 | } 23 | 24 | func trimQuotes(value string) string { 25 | lastIndex := len(value) - 1 26 | for _, char := range []byte{'\'', '"'} { 27 | if value[0] == char && value[lastIndex] == char { 28 | return value[1:lastIndex] 29 | } 30 | } 31 | return value 32 | } 33 | 34 | // NewQuotedString returns a new quoted string option 35 | func NewQuotedString(value *string) *QuotedString { 36 | return &QuotedString{value: value} 37 | } 38 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/README.md: -------------------------------------------------------------------------------- 1 | This code provides helper functions for dealing with archive files. 2 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/archive_other.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package archive 4 | 5 | func getWhiteoutConverter(format WhiteoutFormat) tarWhiteoutConverter { 6 | return nil 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/changes_windows.go: -------------------------------------------------------------------------------- 1 | package archive 2 | 3 | import ( 4 | "os" 5 | 6 | "github.com/docker/docker/pkg/system" 7 | ) 8 | 9 | func statDifferent(oldStat *system.StatT, newStat *system.StatT) bool { 10 | 11 | // Don't look at size for dirs, its not a good measure of change 12 | if oldStat.Mtim() != newStat.Mtim() || 13 | oldStat.Mode() != newStat.Mode() || 14 | oldStat.Size() != newStat.Size() && !oldStat.Mode().IsDir() { 15 | return true 16 | } 17 | return false 18 | } 19 | 20 | func (info *FileInfo) isDir() bool { 21 | return info.parent == nil || info.stat.Mode().IsDir() 22 | } 23 | 24 | func getIno(fi os.FileInfo) (inode uint64) { 25 | return 26 | } 27 | 28 | func hasHardlinks(fi os.FileInfo) bool { 29 | return false 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/copy_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package archive 4 | 5 | import ( 6 | "path/filepath" 7 | ) 8 | 9 | func normalizePath(path string) string { 10 | return filepath.ToSlash(path) 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/copy_windows.go: -------------------------------------------------------------------------------- 1 | package archive 2 | 3 | import ( 4 | "path/filepath" 5 | ) 6 | 7 | func normalizePath(path string) string { 8 | return filepath.FromSlash(path) 9 | } 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/time_linux.go: -------------------------------------------------------------------------------- 1 | package archive 2 | 3 | import ( 4 | "syscall" 5 | "time" 6 | ) 7 | 8 | func timeToTimespec(time time.Time) (ts syscall.Timespec) { 9 | if time.IsZero() { 10 | // Return UTIME_OMIT special value 11 | ts.Sec = 0 12 | ts.Nsec = ((1 << 30) - 2) 13 | return 14 | } 15 | return syscall.NsecToTimespec(time.UnixNano()) 16 | } 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/archive/time_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package archive 4 | 5 | import ( 6 | "syscall" 7 | "time" 8 | ) 9 | 10 | func timeToTimespec(time time.Time) (ts syscall.Timespec) { 11 | nsec := int64(0) 12 | if !time.IsZero() { 13 | nsec = time.UnixNano() 14 | } 15 | return syscall.NsecToTimespec(nsec) 16 | } 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/fileutils/fileutils_darwin.go: -------------------------------------------------------------------------------- 1 | package fileutils 2 | 3 | import ( 4 | "os" 5 | "os/exec" 6 | "strconv" 7 | "strings" 8 | ) 9 | 10 | // GetTotalUsedFds returns the number of used File Descriptors by 11 | // executing `lsof -p PID` 12 | func GetTotalUsedFds() int { 13 | pid := os.Getpid() 14 | 15 | cmd := exec.Command("lsof", "-p", strconv.Itoa(pid)) 16 | 17 | output, err := cmd.CombinedOutput() 18 | if err != nil { 19 | return -1 20 | } 21 | 22 | outputStr := strings.TrimSpace(string(output)) 23 | 24 | fds := strings.Split(outputStr, "\n") 25 | 26 | return len(fds) - 1 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/fileutils/fileutils_solaris.go: -------------------------------------------------------------------------------- 1 | package fileutils 2 | 3 | // GetTotalUsedFds Returns the number of used File Descriptors. 4 | // On Solaris these limits are per process and not systemwide 5 | func GetTotalUsedFds() int { 6 | return -1 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/fileutils/fileutils_unix.go: -------------------------------------------------------------------------------- 1 | // +build linux freebsd 2 | 3 | package fileutils 4 | 5 | import ( 6 | "fmt" 7 | "io/ioutil" 8 | "os" 9 | 10 | "github.com/Sirupsen/logrus" 11 | ) 12 | 13 | // GetTotalUsedFds Returns the number of used File Descriptors by 14 | // reading it via /proc filesystem. 15 | func GetTotalUsedFds() int { 16 | if fds, err := ioutil.ReadDir(fmt.Sprintf("/proc/%d/fd", os.Getpid())); err != nil { 17 | logrus.Errorf("Error opening /proc/%d/fd: %s", os.Getpid(), err) 18 | } else { 19 | return len(fds) 20 | } 21 | return -1 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/fileutils/fileutils_windows.go: -------------------------------------------------------------------------------- 1 | package fileutils 2 | 3 | // GetTotalUsedFds Returns the number of used File Descriptors. Not supported 4 | // on Windows. 5 | func GetTotalUsedFds() int { 6 | return -1 7 | } 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/homedir/homedir_linux.go: -------------------------------------------------------------------------------- 1 | // +build linux 2 | 3 | package homedir 4 | 5 | import ( 6 | "os" 7 | 8 | "github.com/docker/docker/pkg/idtools" 9 | ) 10 | 11 | // GetStatic returns the home directory for the current user without calling 12 | // os/user.Current(). This is useful for static-linked binary on glibc-based 13 | // system, because a call to os/user.Current() in a static binary leads to 14 | // segfault due to a glibc issue that won't be fixed in a short term. 15 | // (#29344, golang/go#13470, https://sourceware.org/bugzilla/show_bug.cgi?id=19341) 16 | func GetStatic() (string, error) { 17 | uid := os.Getuid() 18 | usr, err := idtools.LookupUID(uid) 19 | if err != nil { 20 | return "", err 21 | } 22 | return usr.Home, nil 23 | } 24 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/homedir/homedir_others.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package homedir 4 | 5 | import ( 6 | "errors" 7 | ) 8 | 9 | // GetStatic is not needed for non-linux systems. 10 | // (Precisely, it is needed only for glibc-based linux systems.) 11 | func GetStatic() (string, error) { 12 | return "", errors.New("homedir.GetStatic() is not supported on this system") 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/idtools/idtools_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package idtools 4 | 5 | import ( 6 | "os" 7 | 8 | "github.com/docker/docker/pkg/system" 9 | ) 10 | 11 | // Platforms such as Windows do not support the UID/GID concept. So make this 12 | // just a wrapper around system.MkdirAll. 13 | func mkdirAs(path string, mode os.FileMode, ownerUID, ownerGID int, mkAll, chownExisting bool) error { 14 | if err := system.MkdirAll(path, mode); err != nil && !os.IsExist(err) { 15 | return err 16 | } 17 | return nil 18 | } 19 | 20 | // CanAccess takes a valid (existing) directory and a uid, gid pair and determines 21 | // if that uid, gid pair has access (execute bit) to the directory 22 | // Windows does not require/support this function, so always return true 23 | func CanAccess(path string, uid, gid int) bool { 24 | return true 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/idtools/usergroupadd_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package idtools 4 | 5 | import "fmt" 6 | 7 | // AddNamespaceRangesUser takes a name and finds an unused uid, gid pair 8 | // and calls the appropriate helper function to add the group and then 9 | // the user to the group in /etc/group and /etc/passwd respectively. 10 | func AddNamespaceRangesUser(name string) (int, int, error) { 11 | return -1, -1, fmt.Errorf("No support for adding users or groups on this OS") 12 | } 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/idtools/utils_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package idtools 4 | 5 | import ( 6 | "fmt" 7 | "os/exec" 8 | "path/filepath" 9 | "strings" 10 | ) 11 | 12 | func resolveBinary(binname string) (string, error) { 13 | binaryPath, err := exec.LookPath(binname) 14 | if err != nil { 15 | return "", err 16 | } 17 | resolvedPath, err := filepath.EvalSymlinks(binaryPath) 18 | if err != nil { 19 | return "", err 20 | } 21 | //only return no error if the final resolved binary basename 22 | //matches what was searched for 23 | if filepath.Base(resolvedPath) == binname { 24 | return resolvedPath, nil 25 | } 26 | return "", fmt.Errorf("Binary %q does not resolve to a binary of that name in $PATH (%q)", binname, resolvedPath) 27 | } 28 | 29 | func execCmd(cmd, args string) ([]byte, error) { 30 | execCmd := exec.Command(cmd, strings.Split(args, " ")...) 31 | return execCmd.CombinedOutput() 32 | } 33 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/ioutils/temp_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package ioutils 4 | 5 | import "io/ioutil" 6 | 7 | // TempDir on Unix systems is equivalent to ioutil.TempDir. 8 | func TempDir(dir, prefix string) (string, error) { 9 | return ioutil.TempDir(dir, prefix) 10 | } 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/ioutils/temp_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package ioutils 4 | 5 | import ( 6 | "io/ioutil" 7 | 8 | "github.com/docker/docker/pkg/longpath" 9 | ) 10 | 11 | // TempDir is the equivalent of ioutil.TempDir, except that the result is in Windows longpath format. 12 | func TempDir(dir, prefix string) (string, error) { 13 | tempDir, err := ioutil.TempDir(dir, prefix) 14 | if err != nil { 15 | return "", err 16 | } 17 | return longpath.AddPrefix(tempDir), nil 18 | } 19 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/jsonlog/time_marshalling.go: -------------------------------------------------------------------------------- 1 | // Package jsonlog provides helper functions to parse and print time (time.Time) as JSON. 2 | package jsonlog 3 | 4 | import ( 5 | "errors" 6 | "time" 7 | ) 8 | 9 | const ( 10 | // RFC3339NanoFixed is our own version of RFC339Nano because we want one 11 | // that pads the nano seconds part with zeros to ensure 12 | // the timestamps are aligned in the logs. 13 | RFC3339NanoFixed = "2006-01-02T15:04:05.000000000Z07:00" 14 | // JSONFormat is the format used by FastMarshalJSON 15 | JSONFormat = `"` + time.RFC3339Nano + `"` 16 | ) 17 | 18 | // FastTimeMarshalJSON avoids one of the extra allocations that 19 | // time.MarshalJSON is making. 20 | func FastTimeMarshalJSON(t time.Time) (string, error) { 21 | if y := t.Year(); y < 0 || y >= 10000 { 22 | // RFC 3339 is clear that years are 4 digits exactly. 23 | // See golang.org/issue/4556#c15 for more discussion. 24 | return "", errors.New("time.MarshalJSON: year outside of range [0,9999]") 25 | } 26 | return t.Format(JSONFormat), nil 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/longpath/longpath.go: -------------------------------------------------------------------------------- 1 | // longpath introduces some constants and helper functions for handling long paths 2 | // in Windows, which are expected to be prepended with `\\?\` and followed by either 3 | // a drive letter, a UNC server\share, or a volume identifier. 4 | 5 | package longpath 6 | 7 | import ( 8 | "strings" 9 | ) 10 | 11 | // Prefix is the longpath prefix for Windows file paths. 12 | const Prefix = `\\?\` 13 | 14 | // AddPrefix will add the Windows long path prefix to the path provided if 15 | // it does not already have it. 16 | func AddPrefix(path string) string { 17 | if !strings.HasPrefix(path, Prefix) { 18 | if strings.HasPrefix(path, `\\`) { 19 | // This is a UNC path, so we need to add 'UNC' to the path as well. 20 | path = Prefix + `UNC` + path[1:] 21 | } else { 22 | path = Prefix + path 23 | } 24 | } 25 | return path 26 | } 27 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/mount/flags_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux,!freebsd freebsd,!cgo solaris,!cgo 2 | 3 | package mount 4 | 5 | // These flags are unsupported. 6 | const ( 7 | BIND = 0 8 | DIRSYNC = 0 9 | MANDLOCK = 0 10 | NOATIME = 0 11 | NODEV = 0 12 | NODIRATIME = 0 13 | NOEXEC = 0 14 | NOSUID = 0 15 | UNBINDABLE = 0 16 | RUNBINDABLE = 0 17 | PRIVATE = 0 18 | RPRIVATE = 0 19 | SHARED = 0 20 | RSHARED = 0 21 | SLAVE = 0 22 | RSLAVE = 0 23 | RBIND = 0 24 | RELATIME = 0 25 | RELATIVE = 0 26 | REMOUNT = 0 27 | STRICTATIME = 0 28 | SYNCHRONOUS = 0 29 | RDONLY = 0 30 | mntDetach = 0 31 | ) 32 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/mount/mounter_solaris.go: -------------------------------------------------------------------------------- 1 | // +build solaris,cgo 2 | 3 | package mount 4 | 5 | import ( 6 | "golang.org/x/sys/unix" 7 | "unsafe" 8 | ) 9 | 10 | // #include 11 | // #include 12 | // #include 13 | // int Mount(const char *spec, const char *dir, int mflag, 14 | // char *fstype, char *dataptr, int datalen, char *optptr, int optlen) { 15 | // return mount(spec, dir, mflag, fstype, dataptr, datalen, optptr, optlen); 16 | // } 17 | import "C" 18 | 19 | func mount(device, target, mType string, flag uintptr, data string) error { 20 | spec := C.CString(device) 21 | dir := C.CString(target) 22 | fstype := C.CString(mType) 23 | _, err := C.Mount(spec, dir, C.int(flag), fstype, nil, 0, nil, 0) 24 | C.free(unsafe.Pointer(spec)) 25 | C.free(unsafe.Pointer(dir)) 26 | C.free(unsafe.Pointer(fstype)) 27 | return err 28 | } 29 | 30 | func unmount(target string, flag int) error { 31 | err := unix.Unmount(target, flag) 32 | return err 33 | } 34 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/mount/mounter_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux,!freebsd,!solaris freebsd,!cgo solaris,!cgo 2 | 3 | package mount 4 | 5 | func mount(device, target, mType string, flag uintptr, data string) error { 6 | panic("Not implemented") 7 | } 8 | 9 | func unmount(target string, flag int) error { 10 | panic("Not implemented") 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/mount/mountinfo_solaris.go: -------------------------------------------------------------------------------- 1 | // +build solaris,cgo 2 | 3 | package mount 4 | 5 | /* 6 | #include 7 | #include 8 | */ 9 | import "C" 10 | 11 | import ( 12 | "fmt" 13 | ) 14 | 15 | func parseMountTable() ([]*Info, error) { 16 | mnttab := C.fopen(C.CString(C.MNTTAB), C.CString("r")) 17 | if mnttab == nil { 18 | return nil, fmt.Errorf("Failed to open %s", C.MNTTAB) 19 | } 20 | 21 | var out []*Info 22 | var mp C.struct_mnttab 23 | 24 | ret := C.getmntent(mnttab, &mp) 25 | for ret == 0 { 26 | var mountinfo Info 27 | mountinfo.Mountpoint = C.GoString(mp.mnt_mountp) 28 | mountinfo.Source = C.GoString(mp.mnt_special) 29 | mountinfo.Fstype = C.GoString(mp.mnt_fstype) 30 | mountinfo.Opts = C.GoString(mp.mnt_mntopts) 31 | out = append(out, &mountinfo) 32 | ret = C.getmntent(mnttab, &mp) 33 | } 34 | 35 | C.fclose(mnttab) 36 | return out, nil 37 | } 38 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/mount/mountinfo_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !windows,!linux,!freebsd,!solaris freebsd,!cgo solaris,!cgo 2 | 3 | package mount 4 | 5 | import ( 6 | "fmt" 7 | "runtime" 8 | ) 9 | 10 | func parseMountTable() ([]*Info, error) { 11 | return nil, fmt.Errorf("mount.parseMountTable is not implemented on %s/%s", runtime.GOOS, runtime.GOARCH) 12 | } 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/mount/mountinfo_windows.go: -------------------------------------------------------------------------------- 1 | package mount 2 | 3 | func parseMountTable() ([]*Info, error) { 4 | // Do NOT return an error! 5 | return nil, nil 6 | } 7 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/promise/promise.go: -------------------------------------------------------------------------------- 1 | package promise 2 | 3 | // Go is a basic promise implementation: it wraps calls a function in a goroutine, 4 | // and returns a channel which will later return the function's return value. 5 | func Go(f func() error) chan error { 6 | ch := make(chan error, 1) 7 | go func() { 8 | ch <- f() 9 | }() 10 | return ch 11 | } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/chtimes_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package system 4 | 5 | import ( 6 | "time" 7 | ) 8 | 9 | //setCTime will set the create time on a file. On Unix, the create 10 | //time is updated as a side effect of setting the modified time, so 11 | //no action is required. 12 | func setCTime(path string, ctime time.Time) error { 13 | return nil 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/chtimes_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package system 4 | 5 | import ( 6 | "syscall" 7 | "time" 8 | ) 9 | 10 | //setCTime will set the create time on a file. On Windows, this requires 11 | //calling SetFileTime and explicitly including the create time. 12 | func setCTime(path string, ctime time.Time) error { 13 | ctimespec := syscall.NsecToTimespec(ctime.UnixNano()) 14 | pathp, e := syscall.UTF16PtrFromString(path) 15 | if e != nil { 16 | return e 17 | } 18 | h, e := syscall.CreateFile(pathp, 19 | syscall.FILE_WRITE_ATTRIBUTES, syscall.FILE_SHARE_WRITE, nil, 20 | syscall.OPEN_EXISTING, syscall.FILE_FLAG_BACKUP_SEMANTICS, 0) 21 | if e != nil { 22 | return e 23 | } 24 | defer syscall.Close(h) 25 | c := syscall.NsecToFiletime(syscall.TimespecToNsec(ctimespec)) 26 | return syscall.SetFileTime(h, &c, nil, nil) 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/errors.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import ( 4 | "errors" 5 | ) 6 | 7 | var ( 8 | // ErrNotSupportedPlatform means the platform is not supported. 9 | ErrNotSupportedPlatform = errors.New("platform and architecture is not supported") 10 | ) 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/lstat_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package system 4 | 5 | import "syscall" 6 | 7 | // Lstat takes a path to a file and returns 8 | // a system.StatT type pertaining to that file. 9 | // 10 | // Throws an error if the file does not exist 11 | func Lstat(path string) (*StatT, error) { 12 | s := &syscall.Stat_t{} 13 | if err := syscall.Lstat(path, s); err != nil { 14 | return nil, err 15 | } 16 | return fromStatT(s) 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/lstat_windows.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import "os" 4 | 5 | // Lstat calls os.Lstat to get a fileinfo interface back. 6 | // This is then copied into our own locally defined structure. 7 | func Lstat(path string) (*StatT, error) { 8 | fi, err := os.Lstat(path) 9 | if err != nil { 10 | return nil, err 11 | } 12 | 13 | return fromStatT(&fi) 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/meminfo.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | // MemInfo contains memory statistics of the host system. 4 | type MemInfo struct { 5 | // Total usable RAM (i.e. physical RAM minus a few reserved bits and the 6 | // kernel binary code). 7 | MemTotal int64 8 | 9 | // Amount of free memory. 10 | MemFree int64 11 | 12 | // Total amount of swap space available. 13 | SwapTotal int64 14 | 15 | // Amount of swap space that is currently unused. 16 | SwapFree int64 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/meminfo_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux,!windows,!solaris 2 | 3 | package system 4 | 5 | // ReadMemInfo is not supported on platforms other than linux and windows. 6 | func ReadMemInfo() (*MemInfo, error) { 7 | return nil, ErrNotSupportedPlatform 8 | } 9 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/mknod.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package system 4 | 5 | import ( 6 | "syscall" 7 | ) 8 | 9 | // Mknod creates a filesystem node (file, device special file or named pipe) named path 10 | // with attributes specified by mode and dev. 11 | func Mknod(path string, mode uint32, dev int) error { 12 | return syscall.Mknod(path, mode, dev) 13 | } 14 | 15 | // Mkdev is used to build the value of linux devices (in /dev/) which specifies major 16 | // and minor number of the newly created device special file. 17 | // Linux device nodes are a bit weird due to backwards compat with 16 bit device nodes. 18 | // They are, from low to high: the lower 8 bits of the minor, then 12 bits of the major, 19 | // then the top 12 bits of the minor. 20 | func Mkdev(major int64, minor int64) uint32 { 21 | return uint32(((minor & 0xfff00) << 12) | ((major & 0xfff) << 8) | (minor & 0xff)) 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/mknod_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package system 4 | 5 | // Mknod is not implemented on Windows. 6 | func Mknod(path string, mode uint32, dev int) error { 7 | return ErrNotSupportedPlatform 8 | } 9 | 10 | // Mkdev is not implemented on Windows. 11 | func Mkdev(major int64, minor int64) uint32 { 12 | panic("Mkdev not implemented on Windows.") 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/path_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package system 4 | 5 | // DefaultPathEnv is unix style list of directories to search for 6 | // executables. Each directory is separated from the next by a colon 7 | // ':' character . 8 | const DefaultPathEnv = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" 9 | 10 | // CheckSystemDriveAndRemoveDriveLetter verifies that a path, if it includes a drive letter, 11 | // is the system drive. This is a no-op on Linux. 12 | func CheckSystemDriveAndRemoveDriveLetter(path string) (string, error) { 13 | return path, nil 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/process_unix.go: -------------------------------------------------------------------------------- 1 | // +build linux freebsd solaris darwin 2 | 3 | package system 4 | 5 | import ( 6 | "syscall" 7 | ) 8 | 9 | // IsProcessAlive returns true if process with a given pid is running. 10 | func IsProcessAlive(pid int) bool { 11 | err := syscall.Kill(pid, syscall.Signal(0)) 12 | if err == nil || err == syscall.EPERM { 13 | return true 14 | } 15 | 16 | return false 17 | } 18 | 19 | // KillProcess force-stops a process. 20 | func KillProcess(pid int) { 21 | syscall.Kill(pid, syscall.SIGKILL) 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/stat_darwin.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import "syscall" 4 | 5 | // fromStatT converts a syscall.Stat_t type to a system.Stat_t type 6 | func fromStatT(s *syscall.Stat_t) (*StatT, error) { 7 | return &StatT{size: s.Size, 8 | mode: uint32(s.Mode), 9 | uid: s.Uid, 10 | gid: s.Gid, 11 | rdev: uint64(s.Rdev), 12 | mtim: s.Mtimespec}, nil 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/stat_freebsd.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import "syscall" 4 | 5 | // fromStatT converts a syscall.Stat_t type to a system.Stat_t type 6 | func fromStatT(s *syscall.Stat_t) (*StatT, error) { 7 | return &StatT{size: s.Size, 8 | mode: uint32(s.Mode), 9 | uid: s.Uid, 10 | gid: s.Gid, 11 | rdev: uint64(s.Rdev), 12 | mtim: s.Mtimespec}, nil 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/stat_linux.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import "syscall" 4 | 5 | // fromStatT converts a syscall.Stat_t type to a system.Stat_t type 6 | func fromStatT(s *syscall.Stat_t) (*StatT, error) { 7 | return &StatT{size: s.Size, 8 | mode: uint32(s.Mode), 9 | uid: s.Uid, 10 | gid: s.Gid, 11 | rdev: uint64(s.Rdev), 12 | mtim: s.Mtim}, nil 13 | } 14 | 15 | // FromStatT converts a syscall.Stat_t type to a system.Stat_t type 16 | // This is exposed on Linux as pkg/archive/changes uses it. 17 | func FromStatT(s *syscall.Stat_t) (*StatT, error) { 18 | return fromStatT(s) 19 | } 20 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/stat_openbsd.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import "syscall" 4 | 5 | // fromStatT converts a syscall.Stat_t type to a system.Stat_t type 6 | func fromStatT(s *syscall.Stat_t) (*StatT, error) { 7 | return &StatT{size: s.Size, 8 | mode: uint32(s.Mode), 9 | uid: s.Uid, 10 | gid: s.Gid, 11 | rdev: uint64(s.Rdev), 12 | mtim: s.Mtim}, nil 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/stat_solaris.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import "syscall" 4 | 5 | // fromStatT converts a syscall.Stat_t type to a system.Stat_t type 6 | func fromStatT(s *syscall.Stat_t) (*StatT, error) { 7 | return &StatT{size: s.Size, 8 | mode: uint32(s.Mode), 9 | uid: s.Uid, 10 | gid: s.Gid, 11 | rdev: uint64(s.Rdev), 12 | mtim: s.Mtim}, nil 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/syscall_unix.go: -------------------------------------------------------------------------------- 1 | // +build linux freebsd 2 | 3 | package system 4 | 5 | import "syscall" 6 | 7 | // Unmount is a platform-specific helper function to call 8 | // the unmount syscall. 9 | func Unmount(dest string) error { 10 | return syscall.Unmount(dest, 0) 11 | } 12 | 13 | // CommandLineToArgv should not be used on Unix. 14 | // It simply returns commandLine in the only element in the returned array. 15 | func CommandLineToArgv(commandLine string) ([]string, error) { 16 | return []string{commandLine}, nil 17 | } 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/umask.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package system 4 | 5 | import ( 6 | "syscall" 7 | ) 8 | 9 | // Umask sets current process's file mode creation mask to newmask 10 | // and returns oldmask. 11 | func Umask(newmask int) (oldmask int, err error) { 12 | return syscall.Umask(newmask), nil 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/umask_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package system 4 | 5 | // Umask is not supported on the windows platform. 6 | func Umask(newmask int) (oldmask int, err error) { 7 | // should not be called on cli code path 8 | return 0, ErrNotSupportedPlatform 9 | } 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/utimes_freebsd.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import ( 4 | "syscall" 5 | "unsafe" 6 | ) 7 | 8 | // LUtimesNano is used to change access and modification time of the specified path. 9 | // It's used for symbol link file because syscall.UtimesNano doesn't support a NOFOLLOW flag atm. 10 | func LUtimesNano(path string, ts []syscall.Timespec) error { 11 | var _path *byte 12 | _path, err := syscall.BytePtrFromString(path) 13 | if err != nil { 14 | return err 15 | } 16 | 17 | if _, _, err := syscall.Syscall(syscall.SYS_LUTIMES, uintptr(unsafe.Pointer(_path)), uintptr(unsafe.Pointer(&ts[0])), 0); err != 0 && err != syscall.ENOSYS { 18 | return err 19 | } 20 | 21 | return nil 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/utimes_linux.go: -------------------------------------------------------------------------------- 1 | package system 2 | 3 | import ( 4 | "syscall" 5 | "unsafe" 6 | ) 7 | 8 | // LUtimesNano is used to change access and modification time of the specified path. 9 | // It's used for symbol link file because syscall.UtimesNano doesn't support a NOFOLLOW flag atm. 10 | func LUtimesNano(path string, ts []syscall.Timespec) error { 11 | // These are not currently available in syscall 12 | atFdCwd := -100 13 | atSymLinkNoFollow := 0x100 14 | 15 | var _path *byte 16 | _path, err := syscall.BytePtrFromString(path) 17 | if err != nil { 18 | return err 19 | } 20 | 21 | if _, _, err := syscall.Syscall6(syscall.SYS_UTIMENSAT, uintptr(atFdCwd), uintptr(unsafe.Pointer(_path)), uintptr(unsafe.Pointer(&ts[0])), uintptr(atSymLinkNoFollow), 0, 0); err != 0 && err != syscall.ENOSYS { 22 | return err 23 | } 24 | 25 | return nil 26 | } 27 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/utimes_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux,!freebsd 2 | 3 | package system 4 | 5 | import "syscall" 6 | 7 | // LUtimesNano is only supported on linux and freebsd. 8 | func LUtimesNano(path string, ts []syscall.Timespec) error { 9 | return ErrNotSupportedPlatform 10 | } 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/system/xattrs_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package system 4 | 5 | // Lgetxattr is not supported on platforms other than linux. 6 | func Lgetxattr(path string, attr string) ([]byte, error) { 7 | return nil, ErrNotSupportedPlatform 8 | } 9 | 10 | // Lsetxattr is not supported on platforms other than linux. 11 | func Lsetxattr(path string, attr string, data []byte, flags int) error { 12 | return ErrNotSupportedPlatform 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/term/tc.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | // +build !solaris !cgo 3 | 4 | package term 5 | 6 | import ( 7 | "syscall" 8 | "unsafe" 9 | 10 | "golang.org/x/sys/unix" 11 | ) 12 | 13 | func tcget(fd uintptr, p *Termios) syscall.Errno { 14 | _, _, err := unix.Syscall(unix.SYS_IOCTL, fd, uintptr(getTermios), uintptr(unsafe.Pointer(p))) 15 | return err 16 | } 17 | 18 | func tcset(fd uintptr, p *Termios) syscall.Errno { 19 | _, _, err := unix.Syscall(unix.SYS_IOCTL, fd, setTermios, uintptr(unsafe.Pointer(p))) 20 | return err 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/term/windows/console.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package windowsconsole 4 | 5 | import ( 6 | "os" 7 | 8 | "github.com/Azure/go-ansiterm/winterm" 9 | ) 10 | 11 | // GetHandleInfo returns file descriptor and bool indicating whether the file is a console. 12 | func GetHandleInfo(in interface{}) (uintptr, bool) { 13 | switch t := in.(type) { 14 | case *ansiReader: 15 | return t.Fd(), true 16 | case *ansiWriter: 17 | return t.Fd(), true 18 | } 19 | 20 | var inFd uintptr 21 | var isTerminal bool 22 | 23 | if file, ok := in.(*os.File); ok { 24 | inFd = file.Fd() 25 | isTerminal = IsConsole(inFd) 26 | } 27 | return inFd, isTerminal 28 | } 29 | 30 | // IsConsole returns true if the given file descriptor is a Windows Console. 31 | // The code assumes that GetConsoleMode will return an error for file descriptors that are not a console. 32 | func IsConsole(fd uintptr) bool { 33 | _, e := winterm.GetConsoleMode(fd) 34 | return e == nil 35 | } 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/term/windows/windows.go: -------------------------------------------------------------------------------- 1 | // These files implement ANSI-aware input and output streams for use by the Docker Windows client. 2 | // When asked for the set of standard streams (e.g., stdin, stdout, stderr), the code will create 3 | // and return pseudo-streams that convert ANSI sequences to / from Windows Console API calls. 4 | 5 | package windowsconsole 6 | 7 | import ( 8 | "io/ioutil" 9 | "os" 10 | "sync" 11 | 12 | ansiterm "github.com/Azure/go-ansiterm" 13 | "github.com/Sirupsen/logrus" 14 | ) 15 | 16 | var logger *logrus.Logger 17 | var initOnce sync.Once 18 | 19 | func initLogger() { 20 | initOnce.Do(func() { 21 | logFile := ioutil.Discard 22 | 23 | if isDebugEnv := os.Getenv(ansiterm.LogEnv); isDebugEnv == "1" { 24 | logFile, _ = os.Create("ansiReaderWriter.log") 25 | } 26 | 27 | logger = &logrus.Logger{ 28 | Out: logFile, 29 | Formatter: new(logrus.TextFormatter), 30 | Level: logrus.DebugLevel, 31 | } 32 | }) 33 | } 34 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/pkg/term/winsize.go: -------------------------------------------------------------------------------- 1 | // +build !solaris,!windows 2 | 3 | package term 4 | 5 | import ( 6 | "unsafe" 7 | 8 | "golang.org/x/sys/unix" 9 | ) 10 | 11 | // GetWinsize returns the window size based on the specified file descriptor. 12 | func GetWinsize(fd uintptr) (*Winsize, error) { 13 | ws := &Winsize{} 14 | _, _, err := unix.Syscall(unix.SYS_IOCTL, fd, uintptr(unix.TIOCGWINSZ), uintptr(unsafe.Pointer(ws))) 15 | // Skipp errno = 0 16 | if err == 0 { 17 | return ws, nil 18 | } 19 | return ws, err 20 | } 21 | 22 | // SetWinsize tries to set the specified window size for the specified file descriptor. 23 | func SetWinsize(fd uintptr, ws *Winsize) error { 24 | _, _, err := unix.Syscall(unix.SYS_IOCTL, fd, uintptr(unix.TIOCSWINSZ), uintptr(unsafe.Pointer(ws))) 25 | // Skipp errno = 0 26 | if err == 0 { 27 | return nil 28 | } 29 | return err 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/docker/project/CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | ../CONTRIBUTING.md -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-connections/sockets/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aws/amazon-ecs-init/9332428bb18f16788bc6a905c61c17736937f6b8/ecs-init/vendor/github.com/docker/go-connections/sockets/README.md -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-connections/sockets/sockets_unix.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package sockets 4 | 5 | import ( 6 | "fmt" 7 | "net" 8 | "net/http" 9 | "syscall" 10 | "time" 11 | ) 12 | 13 | const maxUnixSocketPathSize = len(syscall.RawSockaddrUnix{}.Path) 14 | 15 | func configureUnixTransport(tr *http.Transport, proto, addr string) error { 16 | if len(addr) > maxUnixSocketPathSize { 17 | return fmt.Errorf("Unix socket path %q is too long", addr) 18 | } 19 | // No need for compression in local communications. 20 | tr.DisableCompression = true 21 | tr.Dial = func(_, _ string) (net.Conn, error) { 22 | return net.DialTimeout(proto, addr, defaultTimeout) 23 | } 24 | return nil 25 | } 26 | 27 | func configureNpipeTransport(tr *http.Transport, proto, addr string) error { 28 | return ErrProtocolNotAvailable 29 | } 30 | 31 | // DialPipe connects to a Windows named pipe. 32 | // This is not supported on other OSes. 33 | func DialPipe(_ string, _ time.Duration) (net.Conn, error) { 34 | return nil, syscall.EAFNOSUPPORT 35 | } 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-connections/sockets/sockets_windows.go: -------------------------------------------------------------------------------- 1 | package sockets 2 | 3 | import ( 4 | "net" 5 | "net/http" 6 | "time" 7 | 8 | "github.com/Microsoft/go-winio" 9 | ) 10 | 11 | func configureUnixTransport(tr *http.Transport, proto, addr string) error { 12 | return ErrProtocolNotAvailable 13 | } 14 | 15 | func configureNpipeTransport(tr *http.Transport, proto, addr string) error { 16 | // No need for compression in local communications. 17 | tr.DisableCompression = true 18 | tr.Dial = func(_, _ string) (net.Conn, error) { 19 | return DialPipe(addr, defaultTimeout) 20 | } 21 | return nil 22 | } 23 | 24 | // DialPipe connects to a Windows named pipe. 25 | func DialPipe(addr string, timeout time.Duration) (net.Conn, error) { 26 | return winio.DialPipe(addr, &timeout) 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-connections/sockets/tcp_socket.go: -------------------------------------------------------------------------------- 1 | // Package sockets provides helper functions to create and configure Unix or TCP sockets. 2 | package sockets 3 | 4 | import ( 5 | "crypto/tls" 6 | "net" 7 | ) 8 | 9 | // NewTCPSocket creates a TCP socket listener with the specified address and 10 | // the specified tls configuration. If TLSConfig is set, will encapsulate the 11 | // TCP listener inside a TLS one. 12 | func NewTCPSocket(addr string, tlsConfig *tls.Config) (net.Listener, error) { 13 | l, err := net.Listen("tcp", addr) 14 | if err != nil { 15 | return nil, err 16 | } 17 | if tlsConfig != nil { 18 | tlsConfig.NextProtos = []string{"http/1.1"} 19 | l = tls.NewListener(l, tlsConfig) 20 | } 21 | return l, nil 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-connections/sockets/unix_socket.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package sockets 4 | 5 | import ( 6 | "net" 7 | "os" 8 | "syscall" 9 | ) 10 | 11 | // NewUnixSocket creates a unix socket with the specified path and group. 12 | func NewUnixSocket(path string, gid int) (net.Listener, error) { 13 | if err := syscall.Unlink(path); err != nil && !os.IsNotExist(err) { 14 | return nil, err 15 | } 16 | mask := syscall.Umask(0777) 17 | defer syscall.Umask(mask) 18 | 19 | l, err := net.Listen("unix", path) 20 | if err != nil { 21 | return nil, err 22 | } 23 | if err := os.Chown(path, 0, gid); err != nil { 24 | l.Close() 25 | return nil, err 26 | } 27 | if err := os.Chmod(path, 0660); err != nil { 28 | l.Close() 29 | return nil, err 30 | } 31 | return l, nil 32 | } 33 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/NOTICE: -------------------------------------------------------------------------------- 1 | Docker 2 | Copyright 2012-2015 Docker, Inc. 3 | 4 | This product includes software developed at Docker, Inc. (https://www.docker.com). 5 | 6 | This product contains software (https://github.com/kr/pty) developed 7 | by Keith Rarick, licensed under the MIT License. 8 | 9 | The following is courtesy of our legal counsel: 10 | 11 | 12 | Use and transfer of Docker may be subject to certain restrictions by the 13 | United States and other governments. 14 | It is your responsibility to ensure that your use and/or transfer does not 15 | violate applicable laws. 16 | 17 | For more information, please see https://www.bis.doc.gov 18 | 19 | See also https://www.apache.org/dev/crypto.html and/or seek legal counsel. 20 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/pool.go: -------------------------------------------------------------------------------- 1 | package sdk 2 | 3 | import ( 4 | "io" 5 | "sync" 6 | ) 7 | 8 | const buffer32K = 32 * 1024 9 | 10 | var buffer32KPool = &sync.Pool{New: func() interface{} { return make([]byte, buffer32K) }} 11 | 12 | // copyBuf uses a shared buffer pool with io.CopyBuffer 13 | func copyBuf(w io.Writer, r io.Reader) (int64, error) { 14 | buf := buffer32KPool.Get().([]byte) 15 | written, err := io.CopyBuffer(w, r, buf) 16 | buffer32KPool.Put(buf) 17 | return written, err 18 | } 19 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/tcp_listener.go: -------------------------------------------------------------------------------- 1 | package sdk 2 | 3 | import ( 4 | "crypto/tls" 5 | "net" 6 | "runtime" 7 | 8 | "github.com/docker/go-connections/sockets" 9 | ) 10 | 11 | func newTCPListener(address, pluginName, daemonDir string, tlsConfig *tls.Config) (net.Listener, string, error) { 12 | listener, err := sockets.NewTCPSocket(address, tlsConfig) 13 | if err != nil { 14 | return nil, "", err 15 | } 16 | 17 | addr := listener.Addr().String() 18 | 19 | var specDir string 20 | if runtime.GOOS == "windows" { 21 | specDir, err = createPluginSpecDirWindows(pluginName, addr, daemonDir) 22 | } else { 23 | specDir, err = createPluginSpecDirUnix(pluginName, addr) 24 | } 25 | if err != nil { 26 | return nil, "", err 27 | } 28 | 29 | specFile, err := writeSpecFile(pluginName, addr, specDir, protoTCP) 30 | if err != nil { 31 | return nil, "", err 32 | } 33 | return listener, specFile, nil 34 | } 35 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/unix_listener.go: -------------------------------------------------------------------------------- 1 | // +build linux freebsd 2 | 3 | package sdk 4 | 5 | import ( 6 | "net" 7 | "os" 8 | "path/filepath" 9 | 10 | "github.com/docker/go-connections/sockets" 11 | ) 12 | 13 | const pluginSockDir = "/run/docker/plugins" 14 | 15 | func newUnixListener(pluginName string, gid int) (net.Listener, string, error) { 16 | path, err := fullSocketAddress(pluginName) 17 | if err != nil { 18 | return nil, "", err 19 | } 20 | listener, err := sockets.NewUnixSocket(path, gid) 21 | if err != nil { 22 | return nil, "", err 23 | } 24 | return listener, path, nil 25 | } 26 | 27 | func fullSocketAddress(address string) (string, error) { 28 | if err := os.MkdirAll(pluginSockDir, 0755); err != nil { 29 | return "", err 30 | } 31 | if filepath.IsAbs(address) { 32 | return address, nil 33 | } 34 | return filepath.Join(pluginSockDir, address+".sock"), nil 35 | } 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/unix_listener_nosystemd.go: -------------------------------------------------------------------------------- 1 | // +build linux freebsd 2 | // +build nosystemd 3 | 4 | package sdk 5 | 6 | import "net" 7 | 8 | func setupSocketActivation() (net.Listener, error) { 9 | return nil, nil 10 | } 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/unix_listener_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux,!freebsd 2 | 3 | package sdk 4 | 5 | import ( 6 | "errors" 7 | "net" 8 | ) 9 | 10 | var ( 11 | errOnlySupportedOnLinuxAndFreeBSD = errors.New("unix socket creation is only supported on Linux and FreeBSD") 12 | ) 13 | 14 | func newUnixListener(pluginName string, gid int) (net.Listener, string, error) { 15 | return nil, "", errOnlySupportedOnLinuxAndFreeBSD 16 | } 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/windows_listener_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package sdk 4 | 5 | import ( 6 | "errors" 7 | "net" 8 | ) 9 | 10 | var ( 11 | errOnlySupportedOnWindows = errors.New("named pipe creation is only supported on Windows") 12 | ) 13 | 14 | func newWindowsListener(address, pluginName, daemonRoot string, pipeConfig *WindowsPipeConfig) (net.Listener, string, error) { 15 | return nil, "", errOnlySupportedOnWindows 16 | } 17 | 18 | func windowsCreateDirectoryWithACL(name string) error { 19 | return nil 20 | } 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-plugins-helpers/sdk/windows_pipe_config.go: -------------------------------------------------------------------------------- 1 | package sdk 2 | 3 | // WindowsPipeConfig is a helper structure for configuring named pipe parameters on Windows. 4 | type WindowsPipeConfig struct { 5 | // SecurityDescriptor contains a Windows security descriptor in SDDL format. 6 | SecurityDescriptor string 7 | 8 | // InBufferSize in bytes. 9 | InBufferSize int32 10 | 11 | // OutBufferSize in bytes. 12 | OutBufferSize int32 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-units/MAINTAINERS: -------------------------------------------------------------------------------- 1 | # go-connections maintainers file 2 | # 3 | # This file describes who runs the docker/go-connections project and how. 4 | # This is a living document - if you see something out of date or missing, speak up! 5 | # 6 | # It is structured to be consumable by both humans and programs. 7 | # To extract its contents programmatically, use any TOML-compliant parser. 8 | # 9 | # This file is compiled into the MAINTAINERS file in docker/opensource. 10 | # 11 | [Org] 12 | [Org."Core maintainers"] 13 | people = [ 14 | "calavera", 15 | ] 16 | 17 | [people] 18 | 19 | # A reference list of all people associated with the project. 20 | # All other sections should refer to people by their canonical key 21 | # in the people section. 22 | 23 | # ADD YOURSELF HERE IN ALPHABETICAL ORDER 24 | [people.calavera] 25 | Name = "David Calavera" 26 | Email = "david.calavera@gmail.com" 27 | GitHub = "calavera" 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-units/README.md: -------------------------------------------------------------------------------- 1 | [![GoDoc](https://godoc.org/github.com/docker/go-units?status.svg)](https://godoc.org/github.com/docker/go-units) 2 | 3 | # Introduction 4 | 5 | go-units is a library to transform human friendly measurements into machine friendly values. 6 | 7 | ## Usage 8 | 9 | See the [docs in godoc](https://godoc.org/github.com/docker/go-units) for examples and documentation. 10 | 11 | ## Copyright and license 12 | 13 | Copyright © 2015 Docker, Inc. 14 | 15 | go-units is licensed under the Apache License, Version 2.0. 16 | See [LICENSE](LICENSE) for the full text of the license. 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/docker/go-units/circle.yml: -------------------------------------------------------------------------------- 1 | dependencies: 2 | post: 3 | # install golint 4 | - go get github.com/golang/lint/golint 5 | 6 | test: 7 | pre: 8 | # run analysis before tests 9 | - go vet ./... 10 | - test -z "$(golint ./... | tee /dev/stderr)" 11 | - test -z "$(gofmt -s -l . | tee /dev/stderr)" 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/fsouza/go-dockerclient/.gitignore: -------------------------------------------------------------------------------- 1 | # temporary symlink for testing 2 | testing/data/symlink 3 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/fsouza/go-dockerclient/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | sudo: required 3 | go: 4 | - 1.8.x 5 | - 1.9 6 | - tip 7 | os: 8 | - linux 9 | - osx 10 | env: 11 | matrix: 12 | - GOARCH=amd64 DOCKER_PKG_VERSION=17.06.0~ce-0~ubuntu 13 | - GOARCH=386 DOCKER_PKG_VERSION=17.06.0~ce-0~ubuntu 14 | - GOARCH=amd64 DOCKER_PKG_VERSION=17.05.0~ce-0~ubuntu-trusty 15 | - GOARCH=386 DOCKER_PKG_VERSION=17.05.0~ce-0~ubuntu-trusty 16 | global: 17 | - GO_TEST_FLAGS=-race 18 | - DOCKER_HOST=tcp://127.0.0.1:2375 19 | install: 20 | - make testdeps 21 | - travis_retry travis-scripts/install-docker.bash 22 | script: 23 | - travis-scripts/run-tests.bash 24 | services: 25 | - docker 26 | matrix: 27 | fast_finish: true 28 | exclude: 29 | - os: osx 30 | env: GOARCH=amd64 DOCKER_PKG_VERSION=17.05.0~ce-0~ubuntu-trusty 31 | - os: osx 32 | env: GOARCH=386 DOCKER_PKG_VERSION=17.05.0~ce-0~ubuntu-trusty 33 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/fsouza/go-dockerclient/DOCKER-LICENSE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | You can find the Docker license at the following link: 6 | https://raw.githubusercontent.com/docker/docker/master/LICENSE 7 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/fsouza/go-dockerclient/Makefile: -------------------------------------------------------------------------------- 1 | .PHONY: \ 2 | all \ 3 | lint \ 4 | vet \ 5 | fmt \ 6 | fmtcheck \ 7 | pretest \ 8 | test \ 9 | integration \ 10 | clean 11 | 12 | all: test 13 | 14 | lint: 15 | @ go get -v github.com/golang/lint/golint 16 | [ -z "$$(golint . | grep -v 'type name will be used as docker.DockerInfo' | grep -v 'context.Context should be the first' | tee /dev/stderr)" ] 17 | 18 | vet: 19 | go vet ./... 20 | 21 | fmt: 22 | gofmt -s -w . 23 | 24 | fmtcheck: 25 | [ -z "$$(gofmt -s -d . | tee /dev/stderr)" ] 26 | 27 | testdeps: 28 | go get -d -t ./... 29 | 30 | pretest: testdeps lint vet fmtcheck 31 | 32 | gotest: 33 | go test $(GO_TEST_FLAGS) ./... 34 | 35 | test: pretest gotest 36 | 37 | integration: 38 | go test -tags docker_integration -run TestIntegration -v 39 | 40 | clean: 41 | go clean ./... 42 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/fsouza/go-dockerclient/appveyor.yml: -------------------------------------------------------------------------------- 1 | version: '{build}' 2 | platform: x64 3 | clone_depth: 2 4 | clone_folder: c:\gopath\src\github.com\fsouza\go-dockerclient 5 | environment: 6 | GOPATH: c:\gopath 7 | matrix: 8 | - GOVERSION: 1.8.3 9 | - GOVERSION: 1.9 10 | install: 11 | - set PATH=%GOPATH%\bin;c:\go\bin;%PATH% 12 | - rmdir c:\go /s /q 13 | - appveyor DownloadFile https://storage.googleapis.com/golang/go%GOVERSION%.windows-amd64.zip 14 | - 7z x go%GOVERSION%.windows-amd64.zip -y -oC:\ > NUL 15 | build_script: 16 | - go get -race -d -t ./... 17 | test_script: 18 | - go test -race ./... 19 | matrix: 20 | fast_finish: true 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/fsouza/go-dockerclient/client_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 go-dockerclient authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !windows 6 | 7 | package docker 8 | 9 | import ( 10 | "context" 11 | "net" 12 | "net/http" 13 | ) 14 | 15 | // initializeNativeClient initializes the native Unix domain socket client on 16 | // Unix-style operating systems 17 | func (c *Client) initializeNativeClient() { 18 | if c.endpointURL.Scheme != unixProtocol { 19 | return 20 | } 21 | socketPath := c.endpointURL.Path 22 | tr := defaultTransport() 23 | tr.Dial = func(network, addr string) (net.Conn, error) { 24 | return c.Dialer.Dial(unixProtocol, socketPath) 25 | } 26 | tr.DialContext = func(ctx context.Context, network, addr string) (net.Conn, error) { 27 | return c.Dialer.Dial(unixProtocol, socketPath) 28 | } 29 | c.nativeHTTPClient = &http.Client{Transport: tr} 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/golang/mock/AUTHORS: -------------------------------------------------------------------------------- 1 | # This is the official list of GoMock authors for copyright purposes. 2 | # This file is distinct from the CONTRIBUTORS files. 3 | # See the latter for an explanation. 4 | 5 | # Names should be added to this file as 6 | # Name or Organization 7 | # The email address is not required for organizations. 8 | 9 | # Please keep the list sorted. 10 | 11 | Alex Reece 12 | Google Inc. 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/jmespath/go-jmespath/.gitignore: -------------------------------------------------------------------------------- 1 | /jpgo 2 | jmespath-fuzz.zip 3 | cpu.out 4 | go-jmespath.test 5 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/jmespath/go-jmespath/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | sudo: false 4 | 5 | go: 6 | - 1.4 7 | 8 | install: go get -v -t ./... 9 | script: make test 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/jmespath/go-jmespath/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2015 James Saryerwinnie 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/jmespath/go-jmespath/README.md: -------------------------------------------------------------------------------- 1 | # go-jmespath - A JMESPath implementation in Go 2 | 3 | [![Build Status](https://img.shields.io/travis/jmespath/go-jmespath.svg)](https://travis-ci.org/jmespath/go-jmespath) 4 | 5 | 6 | 7 | See http://jmespath.org for more info. 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/jmespath/go-jmespath/astnodetype_string.go: -------------------------------------------------------------------------------- 1 | // generated by stringer -type astNodeType; DO NOT EDIT 2 | 3 | package jmespath 4 | 5 | import "fmt" 6 | 7 | const _astNodeType_name = "ASTEmptyASTComparatorASTCurrentNodeASTExpRefASTFunctionExpressionASTFieldASTFilterProjectionASTFlattenASTIdentityASTIndexASTIndexExpressionASTKeyValPairASTLiteralASTMultiSelectHashASTMultiSelectListASTOrExpressionASTAndExpressionASTNotExpressionASTPipeASTProjectionASTSubexpressionASTSliceASTValueProjection" 8 | 9 | var _astNodeType_index = [...]uint16{0, 8, 21, 35, 44, 65, 73, 92, 102, 113, 121, 139, 152, 162, 180, 198, 213, 229, 245, 252, 265, 281, 289, 307} 10 | 11 | func (i astNodeType) String() string { 12 | if i < 0 || i >= astNodeType(len(_astNodeType_index)-1) { 13 | return fmt.Sprintf("astNodeType(%d)", i) 14 | } 15 | return _astNodeType_name[_astNodeType_index[i]:_astNodeType_index[i+1]] 16 | } 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/jmespath/go-jmespath/toktype_string.go: -------------------------------------------------------------------------------- 1 | // generated by stringer -type=tokType; DO NOT EDIT 2 | 3 | package jmespath 4 | 5 | import "fmt" 6 | 7 | const _tokType_name = "tUnknowntStartDottFiltertFlattentLparentRparentLbrackettRbrackettLbracetRbracetOrtPipetNumbertUnquotedIdentifiertQuotedIdentifiertCommatColontLTtLTEtGTtGTEtEQtNEtJSONLiteraltStringLiteraltCurrenttExpreftAndtNottEOF" 8 | 9 | var _tokType_index = [...]uint8{0, 8, 13, 17, 24, 32, 39, 46, 55, 64, 71, 78, 81, 86, 93, 112, 129, 135, 141, 144, 148, 151, 155, 158, 161, 173, 187, 195, 202, 206, 210, 214} 10 | 11 | func (i tokType) String() string { 12 | if i < 0 || i >= tokType(len(_tokType_index)-1) { 13 | return fmt.Sprintf("tokType(%d)", i) 14 | } 15 | return _tokType_name[_tokType_index[i]:_tokType_index[i+1]] 16 | } 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/go-digest/.mailmap: -------------------------------------------------------------------------------- 1 | Stephen J Day 2 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/go-digest/.pullapprove.yml: -------------------------------------------------------------------------------- 1 | approve_by_comment: true 2 | approve_regex: '^(Approved|lgtm|LGTM|:shipit:|:star:|:\+1:|:ship:)' 3 | reject_regex: ^Rejected 4 | reset_on_push: true 5 | author_approval: ignored 6 | signed_off_by: 7 | required: true 8 | reviewers: 9 | teams: 10 | - go-digest-maintainers 11 | name: default 12 | required: 2 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/go-digest/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - 1.7 4 | - master 5 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/go-digest/MAINTAINERS: -------------------------------------------------------------------------------- 1 | Aaron Lehmann (@aaronlehmann) 2 | Brandon Philips (@philips) 3 | Brendan Burns (@brendandburns) 4 | Derek McGowan (@dmcgowan) 5 | Jason Bouzane (@jbouzane) 6 | John Starks (@jstarks) 7 | Jonathan Boulle (@jonboulle) 8 | Stephen Day (@stevvooe) 9 | Vincent Batts (@vbatts) 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/NOTICE: -------------------------------------------------------------------------------- 1 | runc 2 | 3 | Copyright 2012-2015 Docker, Inc. 4 | 5 | This product includes software developed at Docker, Inc. (http://www.docker.com). 6 | 7 | The following is courtesy of our legal counsel: 8 | 9 | 10 | Use and transfer of Docker may be subject to certain restrictions by the 11 | United States and other governments. 12 | It is your responsibility to ensure that your use and/or transfer does not 13 | violate applicable laws. 14 | 15 | For more information, please see http://www.bis.doc.gov 16 | 17 | See also http://www.apache.org/dev/crypto.html and/or seek legal counsel. 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/system/syscall_linux_386.go: -------------------------------------------------------------------------------- 1 | // +build linux,386 2 | 3 | package system 4 | 5 | import ( 6 | "golang.org/x/sys/unix" 7 | ) 8 | 9 | // Setuid sets the uid of the calling thread to the specified uid. 10 | func Setuid(uid int) (err error) { 11 | _, _, e1 := unix.RawSyscall(unix.SYS_SETUID32, uintptr(uid), 0, 0) 12 | if e1 != 0 { 13 | err = e1 14 | } 15 | return 16 | } 17 | 18 | // Setgid sets the gid of the calling thread to the specified gid. 19 | func Setgid(gid int) (err error) { 20 | _, _, e1 := unix.RawSyscall(unix.SYS_SETGID32, uintptr(gid), 0, 0) 21 | if e1 != 0 { 22 | err = e1 23 | } 24 | return 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/system/syscall_linux_64.go: -------------------------------------------------------------------------------- 1 | // +build linux,arm64 linux,amd64 linux,ppc linux,ppc64 linux,ppc64le linux,s390x 2 | 3 | package system 4 | 5 | import ( 6 | "golang.org/x/sys/unix" 7 | ) 8 | 9 | // Setuid sets the uid of the calling thread to the specified uid. 10 | func Setuid(uid int) (err error) { 11 | _, _, e1 := unix.RawSyscall(unix.SYS_SETUID, uintptr(uid), 0, 0) 12 | if e1 != 0 { 13 | err = e1 14 | } 15 | return 16 | } 17 | 18 | // Setgid sets the gid of the calling thread to the specified gid. 19 | func Setgid(gid int) (err error) { 20 | _, _, e1 := unix.RawSyscall(unix.SYS_SETGID, uintptr(gid), 0, 0) 21 | if e1 != 0 { 22 | err = e1 23 | } 24 | return 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/system/syscall_linux_arm.go: -------------------------------------------------------------------------------- 1 | // +build linux,arm 2 | 3 | package system 4 | 5 | import ( 6 | "golang.org/x/sys/unix" 7 | ) 8 | 9 | // Setuid sets the uid of the calling thread to the specified uid. 10 | func Setuid(uid int) (err error) { 11 | _, _, e1 := unix.RawSyscall(unix.SYS_SETUID32, uintptr(uid), 0, 0) 12 | if e1 != 0 { 13 | err = e1 14 | } 15 | return 16 | } 17 | 18 | // Setgid sets the gid of the calling thread to the specified gid. 19 | func Setgid(gid int) (err error) { 20 | _, _, e1 := unix.RawSyscall(unix.SYS_SETGID32, uintptr(gid), 0, 0) 21 | if e1 != 0 { 22 | err = e1 23 | } 24 | return 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/system/sysconfig.go: -------------------------------------------------------------------------------- 1 | // +build cgo,linux cgo,freebsd 2 | 3 | package system 4 | 5 | /* 6 | #include 7 | */ 8 | import "C" 9 | 10 | func GetClockTicks() int { 11 | return int(C.sysconf(C._SC_CLK_TCK)) 12 | } 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/system/sysconfig_notcgo.go: -------------------------------------------------------------------------------- 1 | // +build !cgo windows 2 | 3 | package system 4 | 5 | func GetClockTicks() int { 6 | // TODO figure out a better alternative for platforms where we're missing cgo 7 | // 8 | // TODO Windows. This could be implemented using Win32 QueryPerformanceFrequency(). 9 | // https://msdn.microsoft.com/en-us/library/windows/desktop/ms644905(v=vs.85).aspx 10 | // 11 | // An example of its usage can be found here. 12 | // https://msdn.microsoft.com/en-us/library/windows/desktop/dn553408(v=vs.85).aspx 13 | 14 | return 100 15 | } 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/system/unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package system 4 | 5 | // RunningInUserNS is a stub for non-Linux systems 6 | // Always returns false 7 | func RunningInUserNS() bool { 8 | return false 9 | } 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/user/MAINTAINERS: -------------------------------------------------------------------------------- 1 | Tianon Gravi (@tianon) 2 | Aleksa Sarai (@cyphar) 3 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/user/lookup_unix.go: -------------------------------------------------------------------------------- 1 | // +build darwin dragonfly freebsd linux netbsd openbsd solaris 2 | 3 | package user 4 | 5 | import ( 6 | "io" 7 | "os" 8 | ) 9 | 10 | // Unix-specific path to the passwd and group formatted files. 11 | const ( 12 | unixPasswdPath = "/etc/passwd" 13 | unixGroupPath = "/etc/group" 14 | ) 15 | 16 | func GetPasswdPath() (string, error) { 17 | return unixPasswdPath, nil 18 | } 19 | 20 | func GetPasswd() (io.ReadCloser, error) { 21 | return os.Open(unixPasswdPath) 22 | } 23 | 24 | func GetGroupPath() (string, error) { 25 | return unixGroupPath, nil 26 | } 27 | 28 | func GetGroup() (io.ReadCloser, error) { 29 | return os.Open(unixGroupPath) 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/opencontainers/runc/libcontainer/user/lookup_unsupported.go: -------------------------------------------------------------------------------- 1 | // +build !darwin,!dragonfly,!freebsd,!linux,!netbsd,!openbsd,!solaris 2 | 3 | package user 4 | 5 | import "io" 6 | 7 | func GetPasswdPath() (string, error) { 8 | return "", ErrUnsupported 9 | } 10 | 11 | func GetPasswd() (io.ReadCloser, error) { 12 | return nil, ErrUnsupported 13 | } 14 | 15 | func GetGroupPath() (string, error) { 16 | return "", ErrUnsupported 17 | } 18 | 19 | func GetGroup() (io.ReadCloser, error) { 20 | return nil, ErrUnsupported 21 | } 22 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/pkg/errors/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.prof 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/pkg/errors/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go_import_path: github.com/pkg/errors 3 | go: 4 | - 1.4.x 5 | - 1.5.x 6 | - 1.6.x 7 | - 1.7.x 8 | - 1.8.x 9 | - tip 10 | 11 | script: 12 | - go test -v ./... 13 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/pkg/errors/appveyor.yml: -------------------------------------------------------------------------------- 1 | version: build-{build}.{branch} 2 | 3 | clone_folder: C:\gopath\src\github.com\pkg\errors 4 | shallow_clone: true # for startup speed 5 | 6 | environment: 7 | GOPATH: C:\gopath 8 | 9 | platform: 10 | - x64 11 | 12 | # http://www.appveyor.com/docs/installed-software 13 | install: 14 | # some helpful output for debugging builds 15 | - go version 16 | - go env 17 | # pre-installed MinGW at C:\MinGW is 32bit only 18 | # but MSYS2 at C:\msys64 has mingw64 19 | - set PATH=C:\msys64\mingw64\bin;%PATH% 20 | - gcc --version 21 | - g++ --version 22 | 23 | build_script: 24 | - go install -v ./... 25 | 26 | test_script: 27 | - set PATH=C:\gopath\bin;%PATH% 28 | - go test -v ./... 29 | 30 | #artifacts: 31 | # - path: '%GOPATH%\bin\*.exe' 32 | deploy: off 33 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/assert/assertion_format.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.CommentFormat}} 2 | func {{.DocInfo.Name}}f(t TestingT, {{.ParamsFormat}}) bool { 3 | if h, ok := t.(tHelper); ok { h.Helper() } 4 | return {{.DocInfo.Name}}(t, {{.ForwardedParamsFormat}}) 5 | } 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/assert/assertion_forward.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.CommentWithoutT "a"}} 2 | func (a *Assertions) {{.DocInfo.Name}}({{.Params}}) bool { 3 | if h, ok := a.t.(tHelper); ok { h.Helper() } 4 | return {{.DocInfo.Name}}(a.t, {{.ForwardedParams}}) 5 | } 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/assert/errors.go: -------------------------------------------------------------------------------- 1 | package assert 2 | 3 | import ( 4 | "errors" 5 | ) 6 | 7 | // AnError is an error instance useful for testing. If the code does not care 8 | // about error specifics, and only needs to return the error for example, this 9 | // error should be used to make the test code more readable. 10 | var AnError = errors.New("assert.AnError general error for testing") 11 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/assert/forward_assertions.go: -------------------------------------------------------------------------------- 1 | package assert 2 | 3 | // Assertions provides assertion methods around the 4 | // TestingT interface. 5 | type Assertions struct { 6 | t TestingT 7 | } 8 | 9 | // New makes a new Assertions object for the specified TestingT. 10 | func New(t TestingT) *Assertions { 11 | return &Assertions{ 12 | t: t, 13 | } 14 | } 15 | 16 | //go:generate go run ../_codegen/main.go -output-package=assert -template=assertion_forward.go.tmpl -include-format-funcs 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/require/doc.go: -------------------------------------------------------------------------------- 1 | // Package require implements the same assertions as the `assert` package but 2 | // stops test execution when a test fails. 3 | // 4 | // Example Usage 5 | // 6 | // The following is a complete example using require in a standard test function: 7 | // import ( 8 | // "testing" 9 | // "github.com/stretchr/testify/require" 10 | // ) 11 | // 12 | // func TestSomething(t *testing.T) { 13 | // 14 | // var a string = "Hello" 15 | // var b string = "Hello" 16 | // 17 | // require.Equal(t, a, b, "The two words should be the same.") 18 | // 19 | // } 20 | // 21 | // Assertions 22 | // 23 | // The `require` package have same global functions as in the `assert` package, 24 | // but instead of returning a boolean result they call `t.FailNow()`. 25 | // 26 | // Every assertion function also takes an optional string message as the final argument, 27 | // allowing custom error messages to be appended to the message the assertion method outputs. 28 | package require 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/require/forward_requirements.go: -------------------------------------------------------------------------------- 1 | package require 2 | 3 | // Assertions provides assertion methods around the 4 | // TestingT interface. 5 | type Assertions struct { 6 | t TestingT 7 | } 8 | 9 | // New makes a new Assertions object for the specified TestingT. 10 | func New(t TestingT) *Assertions { 11 | return &Assertions{ 12 | t: t, 13 | } 14 | } 15 | 16 | //go:generate go run ../_codegen/main.go -output-package=require -template=require_forward.go.tmpl -include-format-funcs 17 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/require/require.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.Comment}} 2 | func {{.DocInfo.Name}}(t TestingT, {{.Params}}) { 3 | if assert.{{.DocInfo.Name}}(t, {{.ForwardedParams}}) { return } 4 | if h, ok := t.(tHelper); ok { h.Helper() } 5 | t.FailNow() 6 | } 7 | -------------------------------------------------------------------------------- /ecs-init/vendor/github.com/stretchr/testify/require/require_forward.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.CommentWithoutT "a"}} 2 | func (a *Assertions) {{.DocInfo.Name}}({{.Params}}) { 3 | if h, ok := a.t.(tHelper); ok { h.Helper() } 4 | {{.DocInfo.Name}}(a.t, {{.ForwardedParams}}) 5 | } 6 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/net/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/net/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/net/proxy/direct.go: -------------------------------------------------------------------------------- 1 | // Copyright 2011 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package proxy 6 | 7 | import ( 8 | "net" 9 | ) 10 | 11 | type direct struct{} 12 | 13 | // Direct is a direct proxy: one that makes network connections directly. 14 | var Direct = direct{} 15 | 16 | func (direct) Dial(network, addr string) (net.Conn, error) { 17 | return net.Dial(network, addr) 18 | } 19 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/.gitignore: -------------------------------------------------------------------------------- 1 | _obj/ 2 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_darwin_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for 386, Darwin 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_darwin_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for AMD64, Darwin 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_darwin_arm.s: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | // +build arm,darwin 7 | 8 | #include "textflag.h" 9 | 10 | // 11 | // System call support for ARM, Darwin 12 | // 13 | 14 | // Just jump to package syscall's implementation for all these functions. 15 | // The runtime may know about them. 16 | 17 | TEXT ·Syscall(SB),NOSPLIT,$0-28 18 | B syscall·Syscall(SB) 19 | 20 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 21 | B syscall·Syscall6(SB) 22 | 23 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 24 | B syscall·Syscall9(SB) 25 | 26 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 27 | B syscall·RawSyscall(SB) 28 | 29 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 30 | B syscall·RawSyscall6(SB) 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_darwin_arm64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | // +build arm64,darwin 7 | 8 | #include "textflag.h" 9 | 10 | // 11 | // System call support for AMD64, Darwin 12 | // 13 | 14 | // Just jump to package syscall's implementation for all these functions. 15 | // The runtime may know about them. 16 | 17 | TEXT ·Syscall(SB),NOSPLIT,$0-56 18 | B syscall·Syscall(SB) 19 | 20 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 21 | B syscall·Syscall6(SB) 22 | 23 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 24 | B syscall·Syscall9(SB) 25 | 26 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 27 | B syscall·RawSyscall(SB) 28 | 29 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 30 | B syscall·RawSyscall6(SB) 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_dragonfly_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for AMD64, DragonFly 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-64 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-88 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-112 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-64 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-88 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_freebsd_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for 386, FreeBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_freebsd_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for AMD64, FreeBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_freebsd_arm.s: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for ARM, FreeBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | B syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | B syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | B syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | B syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | B syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for 386, Linux 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 23 | JMP syscall·RawSyscall(SB) 24 | 25 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 26 | JMP syscall·RawSyscall6(SB) 27 | 28 | TEXT ·socketcall(SB),NOSPLIT,$0-36 29 | JMP syscall·socketcall(SB) 30 | 31 | TEXT ·rawsocketcall(SB),NOSPLIT,$0-36 32 | JMP syscall·rawsocketcall(SB) 33 | 34 | TEXT ·seek(SB),NOSPLIT,$0-28 35 | JMP syscall·seek(SB) 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for AMD64, Linux 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 23 | JMP syscall·RawSyscall(SB) 24 | 25 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 26 | JMP syscall·RawSyscall6(SB) 27 | 28 | TEXT ·gettimeofday(SB),NOSPLIT,$0-16 29 | JMP syscall·gettimeofday(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_arm.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for arm, Linux 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | B syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | B syscall·Syscall6(SB) 21 | 22 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 23 | B syscall·RawSyscall(SB) 24 | 25 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 26 | B syscall·RawSyscall6(SB) 27 | 28 | TEXT ·seek(SB),NOSPLIT,$0-32 29 | B syscall·seek(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_arm64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build linux 6 | // +build arm64 7 | // +build !gccgo 8 | 9 | #include "textflag.h" 10 | 11 | // Just jump to package syscall's implementation for all these functions. 12 | // The runtime may know about them. 13 | 14 | TEXT ·Syscall(SB),NOSPLIT,$0-56 15 | B syscall·Syscall(SB) 16 | 17 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 18 | B syscall·Syscall6(SB) 19 | 20 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 21 | B syscall·RawSyscall(SB) 22 | 23 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 24 | B syscall·RawSyscall6(SB) 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_mips64x.s: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build linux 6 | // +build mips64 mips64le 7 | // +build !gccgo 8 | 9 | #include "textflag.h" 10 | 11 | // 12 | // System calls for mips64, Linux 13 | // 14 | 15 | // Just jump to package syscall's implementation for all these functions. 16 | // The runtime may know about them. 17 | 18 | TEXT ·Syscall(SB),NOSPLIT,$0-56 19 | JMP syscall·Syscall(SB) 20 | 21 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 22 | JMP syscall·Syscall6(SB) 23 | 24 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 25 | JMP syscall·RawSyscall(SB) 26 | 27 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 28 | JMP syscall·RawSyscall6(SB) 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_mipsx.s: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build linux 6 | // +build mips mipsle 7 | // +build !gccgo 8 | 9 | #include "textflag.h" 10 | 11 | // 12 | // System calls for mips, Linux 13 | // 14 | 15 | // Just jump to package syscall's implementation for all these functions. 16 | // The runtime may know about them. 17 | 18 | TEXT ·Syscall(SB),NOSPLIT,$0-28 19 | JMP syscall·Syscall(SB) 20 | 21 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 22 | JMP syscall·Syscall6(SB) 23 | 24 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 25 | JMP syscall·Syscall9(SB) 26 | 27 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 28 | JMP syscall·RawSyscall(SB) 29 | 30 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 31 | JMP syscall·RawSyscall6(SB) 32 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_ppc64x.s: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build linux 6 | // +build ppc64 ppc64le 7 | // +build !gccgo 8 | 9 | #include "textflag.h" 10 | 11 | // 12 | // System calls for ppc64, Linux 13 | // 14 | 15 | // Just jump to package syscall's implementation for all these functions. 16 | // The runtime may know about them. 17 | 18 | TEXT ·Syscall(SB),NOSPLIT,$0-56 19 | BR syscall·Syscall(SB) 20 | 21 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 22 | BR syscall·Syscall6(SB) 23 | 24 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 25 | BR syscall·RawSyscall(SB) 26 | 27 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 28 | BR syscall·RawSyscall6(SB) 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_linux_s390x.s: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build s390x 6 | // +build linux 7 | // +build !gccgo 8 | 9 | #include "textflag.h" 10 | 11 | // 12 | // System calls for s390x, Linux 13 | // 14 | 15 | // Just jump to package syscall's implementation for all these functions. 16 | // The runtime may know about them. 17 | 18 | TEXT ·Syscall(SB),NOSPLIT,$0-56 19 | BR syscall·Syscall(SB) 20 | 21 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 22 | BR syscall·Syscall6(SB) 23 | 24 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 25 | BR syscall·RawSyscall(SB) 26 | 27 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 28 | BR syscall·RawSyscall6(SB) 29 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_netbsd_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for 386, NetBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_netbsd_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for AMD64, NetBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_netbsd_arm.s: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for ARM, NetBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | B syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | B syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | B syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | B syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | B syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_openbsd_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for 386, OpenBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_openbsd_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for AMD64, OpenBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/asm_solaris_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !gccgo 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for amd64, Solaris are implemented in runtime/syscall_solaris.go 11 | // 12 | 13 | TEXT ·sysvicall6(SB),NOSPLIT,$0-88 14 | JMP syscall·sysvicall6(SB) 15 | 16 | TEXT ·rawSysvicall6(SB),NOSPLIT,$0-88 17 | JMP syscall·rawSysvicall6(SB) 18 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/bluetooth_linux.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Bluetooth sockets and messages 6 | 7 | package unix 8 | 9 | // Bluetooth Protocols 10 | const ( 11 | BTPROTO_L2CAP = 0 12 | BTPROTO_HCI = 1 13 | BTPROTO_SCO = 2 14 | BTPROTO_RFCOMM = 3 15 | BTPROTO_BNEP = 4 16 | BTPROTO_CMTP = 5 17 | BTPROTO_HIDP = 6 18 | BTPROTO_AVDTP = 7 19 | ) 20 | 21 | const ( 22 | HCI_CHANNEL_RAW = 0 23 | HCI_CHANNEL_USER = 1 24 | HCI_CHANNEL_MONITOR = 2 25 | HCI_CHANNEL_CONTROL = 3 26 | ) 27 | 28 | // Socketoption Level 29 | const ( 30 | SOL_BLUETOOTH = 0x112 31 | SOL_HCI = 0x0 32 | SOL_L2CAP = 0x6 33 | SOL_RFCOMM = 0x12 34 | SOL_SCO = 0x11 35 | ) 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/constants.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build darwin dragonfly freebsd linux netbsd openbsd solaris 6 | 7 | package unix 8 | 9 | const ( 10 | R_OK = 0x4 11 | W_OK = 0x2 12 | X_OK = 0x1 13 | ) 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/endian_big.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | // 5 | // +build ppc64 s390x mips mips64 6 | 7 | package unix 8 | 9 | const isBigEndian = true 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/endian_little.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | // 5 | // +build 386 amd64 amd64p32 arm arm64 ppc64le mipsle mips64le 6 | 7 | package unix 8 | 9 | const isBigEndian = false 10 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/env_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2010 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build darwin dragonfly freebsd linux netbsd openbsd solaris 6 | 7 | // Unix environment variables. 8 | 9 | package unix 10 | 11 | import "syscall" 12 | 13 | func Getenv(key string) (value string, found bool) { 14 | return syscall.Getenv(key) 15 | } 16 | 17 | func Setenv(key, value string) error { 18 | return syscall.Setenv(key, value) 19 | } 20 | 21 | func Clearenv() { 22 | syscall.Clearenv() 23 | } 24 | 25 | func Environ() []string { 26 | return syscall.Environ() 27 | } 28 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/env_unset.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build go1.4 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | func Unsetenv(key string) error { 12 | // This was added in Go 1.4. 13 | return syscall.Unsetenv(key) 14 | } 15 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/flock.go: -------------------------------------------------------------------------------- 1 | // +build linux darwin freebsd openbsd netbsd dragonfly 2 | 3 | // Copyright 2014 The Go Authors. All rights reserved. 4 | // Use of this source code is governed by a BSD-style 5 | // license that can be found in the LICENSE file. 6 | 7 | // +build darwin dragonfly freebsd linux netbsd openbsd 8 | 9 | package unix 10 | 11 | import "unsafe" 12 | 13 | // fcntl64Syscall is usually SYS_FCNTL, but is overridden on 32-bit Linux 14 | // systems by flock_linux_32bit.go to be SYS_FCNTL64. 15 | var fcntl64Syscall uintptr = SYS_FCNTL 16 | 17 | // FcntlFlock performs a fcntl syscall for the F_GETLK, F_SETLK or F_SETLKW command. 18 | func FcntlFlock(fd uintptr, cmd int, lk *Flock_t) error { 19 | _, _, errno := Syscall(fcntl64Syscall, fd, uintptr(cmd), uintptr(unsafe.Pointer(lk))) 20 | if errno == 0 { 21 | return nil 22 | } 23 | return errno 24 | } 25 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/flock_linux_32bit.go: -------------------------------------------------------------------------------- 1 | // +build linux,386 linux,arm linux,mips linux,mipsle 2 | 3 | // Copyright 2014 The Go Authors. All rights reserved. 4 | // Use of this source code is governed by a BSD-style 5 | // license that can be found in the LICENSE file. 6 | 7 | package unix 8 | 9 | func init() { 10 | // On 32-bit Linux systems, the fcntl syscall that matches Go's 11 | // Flock_t type is SYS_FCNTL64, not SYS_FCNTL. 12 | fcntl64Syscall = SYS_FCNTL64 13 | } 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/gccgo_linux_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build gccgo,linux,amd64 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | //extern gettimeofday 12 | func realGettimeofday(*Timeval, *byte) int32 13 | 14 | func gettimeofday(tv *Timeval) (err syscall.Errno) { 15 | r := realGettimeofday(tv, nil) 16 | if r < 0 { 17 | return syscall.GetErrno() 18 | } 19 | return 0 20 | } 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/gccgo_linux_sparc64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build gccgo,linux,sparc64 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | //extern sysconf 12 | func realSysconf(name int) int64 13 | 14 | func sysconf(name int) (n int64, err syscall.Errno) { 15 | r := realSysconf(name) 16 | if r < 0 { 17 | return 0, syscall.GetErrno() 18 | } 19 | return r, 0 20 | } 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/mksysnum_darwin.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env perl 2 | # Copyright 2009 The Go Authors. All rights reserved. 3 | # Use of this source code is governed by a BSD-style 4 | # license that can be found in the LICENSE file. 5 | # 6 | # Generate system call table for Darwin from sys/syscall.h 7 | 8 | use strict; 9 | 10 | if($ENV{'GOARCH'} eq "" || $ENV{'GOOS'} eq "") { 11 | print STDERR "GOARCH or GOOS not defined in environment\n"; 12 | exit 1; 13 | } 14 | 15 | my $command = "mksysnum_darwin.pl " . join(' ', @ARGV); 16 | 17 | print <){ 29 | if(/^#define\s+SYS_(\w+)\s+([0-9]+)/){ 30 | my $name = $1; 31 | my $num = $2; 32 | $name =~ y/a-z/A-Z/; 33 | print " SYS_$name = $num;" 34 | } 35 | } 36 | 37 | print <= 10 { 20 | buf[i] = byte(val%10 + '0') 21 | i-- 22 | val /= 10 23 | } 24 | buf[i] = byte(val + '0') 25 | return string(buf[i:]) 26 | } 27 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/syscall_linux_amd64_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build amd64,linux 6 | // +build !gccgo 7 | 8 | package unix 9 | 10 | import "syscall" 11 | 12 | //go:noescape 13 | func gettimeofday(tv *Timeval) (err syscall.Errno) 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/syscall_no_getwd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build dragonfly freebsd netbsd openbsd 6 | 7 | package unix 8 | 9 | const ImplementsGetwd = false 10 | 11 | func Getwd() (string, error) { return "", ENOTSUP } 12 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/syscall_solaris_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build amd64,solaris 6 | 7 | package unix 8 | 9 | func TimespecToNsec(ts Timespec) int64 { return int64(ts.Sec)*1e9 + int64(ts.Nsec) } 10 | 11 | func NsecToTimespec(nsec int64) (ts Timespec) { 12 | ts.Sec = nsec / 1e9 13 | ts.Nsec = nsec % 1e9 14 | return 15 | } 16 | 17 | func NsecToTimeval(nsec int64) (tv Timeval) { 18 | nsec += 999 // round up to microsecond 19 | tv.Usec = nsec % 1e9 / 1e3 20 | tv.Sec = int64(nsec / 1e9) 21 | return 22 | } 23 | 24 | func (iov *Iovec) SetLen(length int) { 25 | iov.Len = uint64(length) 26 | } 27 | 28 | func (cmsg *Cmsghdr) SetLen(length int) { 29 | cmsg.Len = uint32(length) 30 | } 31 | 32 | func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) { 33 | // TODO(aram): implement this, see issue 5847. 34 | panic("unimplemented") 35 | } 36 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/syscall_unix_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build darwin dragonfly freebsd linux netbsd openbsd solaris 6 | // +build !gccgo 7 | 8 | package unix 9 | 10 | import "syscall" 11 | 12 | func Syscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) 13 | func Syscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) 14 | func RawSyscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) 15 | func RawSyscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/unix/zsysnum_solaris_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build amd64,solaris 6 | 7 | package unix 8 | 9 | // TODO(aram): remove these before Go 1.3. 10 | const ( 11 | SYS_EXECVE = 59 12 | SYS_FCNTL = 62 13 | ) 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/asm_windows_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // 6 | // System calls for 386, Windows are implemented in runtime/syscall_windows.goc 7 | // 8 | 9 | TEXT ·getprocaddress(SB), 7, $0-8 10 | JMP syscall·getprocaddress(SB) 11 | 12 | TEXT ·loadlibrary(SB), 7, $0-4 13 | JMP syscall·loadlibrary(SB) 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/asm_windows_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // 6 | // System calls for amd64, Windows are implemented in runtime/syscall_windows.goc 7 | // 8 | 9 | TEXT ·getprocaddress(SB), 7, $0-32 10 | JMP syscall·getprocaddress(SB) 11 | 12 | TEXT ·loadlibrary(SB), 7, $0-8 13 | JMP syscall·loadlibrary(SB) 14 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/env_unset.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build windows 6 | // +build go1.4 7 | 8 | package windows 9 | 10 | import "syscall" 11 | 12 | func Unsetenv(key string) error { 13 | // This was added in Go 1.4. 14 | return syscall.Unsetenv(key) 15 | } 16 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/env_windows.go: -------------------------------------------------------------------------------- 1 | // Copyright 2010 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Windows environment variables. 6 | 7 | package windows 8 | 9 | import "syscall" 10 | 11 | func Getenv(key string) (value string, found bool) { 12 | return syscall.Getenv(key) 13 | } 14 | 15 | func Setenv(key, value string) error { 16 | return syscall.Setenv(key, value) 17 | } 18 | 19 | func Clearenv() { 20 | syscall.Clearenv() 21 | } 22 | 23 | func Environ() []string { 24 | return syscall.Environ() 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/eventlog.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build windows 6 | 7 | package windows 8 | 9 | const ( 10 | EVENTLOG_SUCCESS = 0 11 | EVENTLOG_ERROR_TYPE = 1 12 | EVENTLOG_WARNING_TYPE = 2 13 | EVENTLOG_INFORMATION_TYPE = 4 14 | EVENTLOG_AUDIT_SUCCESS = 8 15 | EVENTLOG_AUDIT_FAILURE = 16 16 | ) 17 | 18 | //sys RegisterEventSource(uncServerName *uint16, sourceName *uint16) (handle Handle, err error) [failretval==0] = advapi32.RegisterEventSourceW 19 | //sys DeregisterEventSource(handle Handle) (err error) = advapi32.DeregisterEventSource 20 | //sys ReportEvent(log Handle, etype uint16, category uint16, eventId uint32, usrSId uintptr, numStrings uint16, dataSize uint32, strings **uint16, rawData *byte) (err error) = advapi32.ReportEventW 21 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/mksyscall.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package windows 6 | 7 | //go:generate go run $GOROOT/src/syscall/mksyscall_windows.go -output zsyscall_windows.go eventlog.go service.go syscall_windows.go security_windows.go 8 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/race.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build windows,race 6 | 7 | package windows 8 | 9 | import ( 10 | "runtime" 11 | "unsafe" 12 | ) 13 | 14 | const raceenabled = true 15 | 16 | func raceAcquire(addr unsafe.Pointer) { 17 | runtime.RaceAcquire(addr) 18 | } 19 | 20 | func raceReleaseMerge(addr unsafe.Pointer) { 21 | runtime.RaceReleaseMerge(addr) 22 | } 23 | 24 | func raceReadRange(addr unsafe.Pointer, len int) { 25 | runtime.RaceReadRange(addr, len) 26 | } 27 | 28 | func raceWriteRange(addr unsafe.Pointer, len int) { 29 | runtime.RaceWriteRange(addr, len) 30 | } 31 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/race0.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build windows,!race 6 | 7 | package windows 8 | 9 | import ( 10 | "unsafe" 11 | ) 12 | 13 | const raceenabled = false 14 | 15 | func raceAcquire(addr unsafe.Pointer) { 16 | } 17 | 18 | func raceReleaseMerge(addr unsafe.Pointer) { 19 | } 20 | 21 | func raceReadRange(addr unsafe.Pointer, len int) { 22 | } 23 | 24 | func raceWriteRange(addr unsafe.Pointer, len int) { 25 | } 26 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/str.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build windows 6 | 7 | package windows 8 | 9 | func itoa(val int) string { // do it here rather than with fmt to avoid dependency 10 | if val < 0 { 11 | return "-" + itoa(-val) 12 | } 13 | var buf [32]byte // big enough for int64 14 | i := len(buf) - 1 15 | for val >= 10 { 16 | buf[i] = byte(val%10 + '0') 17 | i-- 18 | val /= 10 19 | } 20 | buf[i] = byte(val + '0') 21 | return string(buf[i:]) 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/ztypes_windows_386.go: -------------------------------------------------------------------------------- 1 | // Copyright 2011 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package windows 6 | 7 | type WSAData struct { 8 | Version uint16 9 | HighVersion uint16 10 | Description [WSADESCRIPTION_LEN + 1]byte 11 | SystemStatus [WSASYS_STATUS_LEN + 1]byte 12 | MaxSockets uint16 13 | MaxUdpDg uint16 14 | VendorInfo *byte 15 | } 16 | 17 | type Servent struct { 18 | Name *byte 19 | Aliases **byte 20 | Port uint16 21 | Proto *byte 22 | } 23 | -------------------------------------------------------------------------------- /ecs-init/vendor/golang.org/x/sys/windows/ztypes_windows_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2011 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package windows 6 | 7 | type WSAData struct { 8 | Version uint16 9 | HighVersion uint16 10 | MaxSockets uint16 11 | MaxUdpDg uint16 12 | VendorInfo *byte 13 | Description [WSADESCRIPTION_LEN + 1]byte 14 | SystemStatus [WSASYS_STATUS_LEN + 1]byte 15 | } 16 | 17 | type Servent struct { 18 | Name *byte 19 | Aliases **byte 20 | Proto *byte 21 | Port uint16 22 | } 23 | -------------------------------------------------------------------------------- /packaging/amazon-linux-ami/amazon-ecs-volume-plugin.conf: -------------------------------------------------------------------------------- 1 | # Copyright 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License. 14 | 15 | description "Amazon Elastic Container Service Volume Plugin" 16 | author "Amazon Web Services" 17 | start on stopped rc RUNLEVEL=[345] 18 | 19 | respawn 20 | respawn limit 10 15 21 | 22 | exec /usr/libexec/amazon-ecs-volume-plugin 23 | -------------------------------------------------------------------------------- /packaging/amazon-linux-ami/amazon-ecs-volume-plugin.service: -------------------------------------------------------------------------------- 1 | # Copyright 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License 14 | 15 | [Unit] 16 | Description=Amazon Elastic Container Service Volume Plugin 17 | After=network.target amazon-ecs-volume-plugin.socket 18 | Requires=amazon-ecs-volume-plugin.socket 19 | 20 | [Service] 21 | Type=simple 22 | Restart=on-failure 23 | RestartSec=10s 24 | ExecStart=/usr/libexec/amazon-ecs-volume-plugin 25 | 26 | [Install] 27 | WantedBy=multi-user.target 28 | -------------------------------------------------------------------------------- /packaging/amazon-linux-ami/amazon-ecs-volume-plugin.socket: -------------------------------------------------------------------------------- 1 | # Copyright 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License 14 | 15 | [Unit] 16 | Description=Amazon Elastic Container Service Volume Plugin 17 | PartOf=amazon-ecs-volume-plugin.service 18 | 19 | [Socket] 20 | ListenStream=/var/run/docker/plugins/amazon-ecs-volume-plugin.sock 21 | 22 | [Install] 23 | WantedBy=sockets.target 24 | -------------------------------------------------------------------------------- /packaging/amazon-linux-ami/ecs.conf: -------------------------------------------------------------------------------- 1 | # Copyright 2014-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License. 14 | 15 | description "Amazon Elastic Container Service init" 16 | author "Amazon Web Services" 17 | start on stopped rc RUNLEVEL=[345] 18 | 19 | pre-start exec /usr/libexec/amazon-ecs-init pre-start 20 | exec /usr/libexec/amazon-ecs-init start 21 | pre-stop exec /usr/libexec/amazon-ecs-init pre-stop 22 | post-stop exec /usr/libexec/amazon-ecs-init post-stop 23 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/README.source: -------------------------------------------------------------------------------- 1 | Steps to build and install package: 2 | 3 | 1. Install build dependencies 4 | sudo apt-get update -y && sudo apt-get install -y devscripts build-essential lintian git curl golang-go debhelper 5 | 6 | 2. Build the package by running 7 | make clean deb 8 | 9 | 3. Install docker 10 | sudo apt-get install docker.io -y # or via docker repos: https://docs.docker.com/engine/install/ 11 | 12 | 4. Install Amazon EFS Utils 13 | Install Amazon EFS Utils either from your distribution's repositories, or manually as described in 14 | https://docs.aws.amazon.com/efs/latest/ug/installing-amazon-efs-utils.html#installing-other-distro 15 | 16 | 5. Install the package with 17 | sudo apt install -y ./amazon-ecs-init_1.45.0-1_amd64.deb 18 | 19 | 6. Install docker and start and enable ecs service 20 | sudo systemctl enable --now ecs 21 | 22 | 7. Start and enable amazon-ecs-volume-plugin 23 | sudo systemctl enable --now amazon-ecs-volume-plugin 24 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/amazon-ecs-init.install: -------------------------------------------------------------------------------- 1 | amazon-ecs-init usr/libexec/ 2 | amazon-ecs-volume-plugin usr/libexec/ 3 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/amazon-ecs-init.manpages: -------------------------------------------------------------------------------- 1 | scripts/amazon-ecs-init.1 2 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/amazon-ecs-volume-plugin.service: -------------------------------------------------------------------------------- 1 | # Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License 14 | 15 | [Unit] 16 | Description=Amazon Elastic Container Service Volume Plugin 17 | After=network.target amazon-ecs-volume-plugin.socket 18 | Requires=amazon-ecs-volume-plugin.socket 19 | 20 | [Service] 21 | Type=simple 22 | Restart=on-failure 23 | RestartSec=10s 24 | ExecStart=/usr/libexec/amazon-ecs-volume-plugin 25 | 26 | [Install] 27 | WantedBy=multi-user.target 28 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/amazon-ecs-volume-plugin.socket: -------------------------------------------------------------------------------- 1 | # Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License 14 | 15 | [Unit] 16 | Description=Amazon Elastic Container Service Volume Plugin 17 | PartOf=amazon-ecs-volume-plugin.service 18 | 19 | [Socket] 20 | ListenStream=/var/run/docker/plugins/amazon-ecs-volume-plugin.sock 21 | 22 | [Install] 23 | WantedBy=sockets.target 24 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/compat: -------------------------------------------------------------------------------- 1 | 9 2 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/control: -------------------------------------------------------------------------------- 1 | Source: amazon-ecs-init 2 | Section: misc 3 | Priority: optional 4 | Maintainer: ecs-agent-dev 5 | Build-Depends: debhelper (>= 9.20160709~), golang-go (>= 1.7) 6 | Standards-Version: 4.3.0 7 | Homepage: https://aws.amazon.com/ecs 8 | Vcs-Git: git://github.com/aws/amazon-ecs-init.git 9 | Vcs-Browser: http://github.com/aws/amazon-ecs-init 10 | 11 | Package: amazon-ecs-init 12 | Architecture: amd64 arm64 13 | Depends: ${shlibs:Depends}, ${misc:Depends}, systemd, docker-ce (>= 17.12.0) | docker-engine (>= 1.6.0) | docker-ee | docker.io 14 | Description: Starts the Amazon ECS Agent 15 | amazon-ecs-init may be run to register an EC2 instance as an Amazon ECS 16 | Container Instance. 17 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/dirs: -------------------------------------------------------------------------------- 1 | etc/ecs 2 | var/log/ecs 3 | var/lib/ecs 4 | var/lib/ecs/data 5 | var/cache/ecs 6 | usr/libexec 7 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/docs: -------------------------------------------------------------------------------- 1 | README.md 2 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | # -*- makefile -*- 3 | VERSION := $(shell dpkg-parsechangelog -S Version) 4 | 5 | # Uncomment this to turn on verbose mode. 6 | export DH_VERBOSE=1 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | ./scripts/gobuild.sh debian 13 | 14 | clean: 15 | dh $@ 16 | rm -f amazon-ecs-init 17 | 18 | override_dh_auto_install: 19 | cp ecs-agent.tar debian/amazon-ecs-init/var/cache/ecs/ecs-agent-v${VERSION}.tar 20 | echo "2" >debian/amazon-ecs-init/var/cache/ecs/state 21 | ln -s "/var/cache/ecs/ecs-agent-v${VERSION}.tar" debian/amazon-ecs-init/var/cache/ecs/ecs-agent.tar 22 | dh_installsystemd --no-start --no-enable --name=ecs 23 | dh_installsystemd --no-start --no-enable --name=amazon-ecs-volume-plugin 24 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/source/format: -------------------------------------------------------------------------------- 1 | 3.0 (quilt) 2 | -------------------------------------------------------------------------------- /packaging/generic-deb/debian/source/include-binaries: -------------------------------------------------------------------------------- 1 | ecs-agent.tar 2 | -------------------------------------------------------------------------------- /packaging/generic-rpm/amazon-ecs-volume-plugin.service: -------------------------------------------------------------------------------- 1 | # Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License 14 | 15 | [Unit] 16 | Description=Amazon Elastic Container Service Volume Plugin 17 | After=network.target amazon-ecs-volume-plugin.socket 18 | Requires=amazon-ecs-volume-plugin.socket 19 | 20 | [Service] 21 | Type=simple 22 | Restart=on-failure 23 | RestartSec=10s 24 | ExecStart=/usr/libexec/amazon-ecs-volume-plugin 25 | 26 | [Install] 27 | WantedBy=multi-user.target 28 | -------------------------------------------------------------------------------- /packaging/generic-rpm/amazon-ecs-volume-plugin.socket: -------------------------------------------------------------------------------- 1 | # Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the 4 | # "License"). You may not use this file except in compliance 5 | # with the License. A copy of the License is located at 6 | # 7 | # http://aws.amazon.com/apache2.0/ 8 | # 9 | # or in the "license" file accompanying this file. This file is 10 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | # CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and 13 | # limitations under the License 14 | 15 | [Unit] 16 | Description=Amazon Elastic Container Service Volume Plugin 17 | PartOf=amazon-ecs-volume-plugin.service 18 | 19 | [Socket] 20 | ListenStream=/var/run/docker/plugins/amazon-ecs-volume-plugin.sock 21 | 22 | [Install] 23 | WantedBy=sockets.target 24 | -------------------------------------------------------------------------------- /packaging/suse/amazon-ecs.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Amazon Elastic Container Service - container agent 3 | Documentation=https://aws.amazon.com/documentation/ecs/ 4 | After=docker.service 5 | After=network.target 6 | Requires=docker.service 7 | Requires=network.target 8 | 9 | [Service] 10 | Type=simple 11 | ExecStartPre=/usr/sbin/amazon-ecs-init pre-start 12 | ExecStart=/usr/sbin/amazon-ecs-init start 13 | ExecStop=/usr/sbin/amazon-ecs-init stop 14 | ExecStopPost=/usr/sbin/amazon-ecs-init post-stop 15 | ExecReload=/usr/sbin/amazon-ecs-init reload-cache 16 | 17 | [Install] 18 | WantedBy=multi-user.target 19 | -------------------------------------------------------------------------------- /scripts/dockerfiles/build.dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2 2 | RUN yum update -y && yum install -y golang make tar rpm-build 3 | WORKDIR /workspace/amazon-ecs-init 4 | # we're going to run the build as the non-privileged user, so we need write access to the directory 5 | RUN chmod -R 777 /workspace 6 | CMD /bin/bash -c 'make rpm' 7 | -------------------------------------------------------------------------------- /scripts/dockerfiles/exit-success.dockerfile: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the 5 | # "License"). You may not use this file except in compliance 6 | # with the License. A copy of the License is located at 7 | # 8 | # http://aws.amazon.com/apache2.0/ 9 | # 10 | # or in the "license" file accompanying this file. This file is 11 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | # CONDITIONS OF ANY KIND, either express or implied. See the 13 | # License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | FROM test.localhost/amazon/mock-ecs-agent 17 | 18 | CMD ["0"] -------------------------------------------------------------------------------- /scripts/dockerfiles/mock-agent.dockerfile: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the 5 | # "License"). You may not use this file except in compliance 6 | # with the License. A copy of the License is located at 7 | # 8 | # http://aws.amazon.com/apache2.0/ 9 | # 10 | # or in the "license" file accompanying this file. This file is 11 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | # CONDITIONS OF ANY KIND, either express or implied. See the 13 | # License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | FROM busybox 17 | 18 | COPY scripts/mock-ecs-agent.sh /mock-ecs-agent.sh 19 | 20 | ENTRYPOINT ["/mock-ecs-agent.sh"] 21 | -------------------------------------------------------------------------------- /scripts/dockerfiles/wants-update.dockerfile: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the 5 | # "License"). You may not use this file except in compliance 6 | # with the License. A copy of the License is located at 7 | # 8 | # http://aws.amazon.com/apache2.0/ 9 | # 10 | # or in the "license" file accompanying this file. This file is 11 | # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | # CONDITIONS OF ANY KIND, either express or implied. See the 13 | # License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | FROM test.localhost/amazon/mock-ecs-agent 17 | 18 | CMD ["42"] -------------------------------------------------------------------------------- /scripts/test: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright 2014-2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"). You may 5 | # not use this file except in compliance with the License. A copy of the 6 | # License is located at 7 | # 8 | # http://aws.amazon.com/apache2.0/ 9 | # 10 | # or in the "license" file accompanying this file. This file is distributed 11 | # on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 12 | # express or implied. See the License for the specific language governing 13 | # permissions and limitations under the License. 14 | set -x 15 | make get-deps 16 | make govet 17 | make test 18 | --------------------------------------------------------------------------------