Switched Protobuf-PHP references to my fork, removed references to git-on-borg

pull/349/head
murgatroid99 10 years ago
parent 1fb40badf1
commit 975a07b949
  1. 27
      src/php/README.md
  2. 3
      tools/dockerfile/grpc_base/README.md
  3. 2
      tools/dockerfile/grpc_java/README.md
  4. 2
      tools/dockerfile/grpc_php/README.md
  5. 6
      tools/dockerfile/grpc_php_base/Dockerfile
  6. 2
      tools/dockerfile/grpc_ruby/README.md
  7. 2
      tools/gce_setup/grpc_docker.sh
  8. 1
      tools/gce_setup/new_grpc_docker_builder.sh
  9. 7
      tools/gce_setup/new_grpc_docker_builder_on_startup.sh
  10. 31
      tools/gce_setup/shared_startup_funcs.sh

@ -7,31 +7,25 @@ Directory structure is as generated by the PHP utility
## ENVIRONMENT
To build a PHP environment that works with this extension, download and extract
PHP 5.5 (5.6 may also work), configure it, and install it:
Install `php5` and `php5-dev`.
```bash
apt-get install libxml2 libxml2-dev
curl http://php.net/get/php-5.5.16.tar.gz
tar -xf php-5.5.16.tar.gz
cd php-5.5.16
./configure --with-zlib=/usr --with-libxml-dir=ext/libxml --with-openssl=/usr/local/ssl
make
make install
```
To run the tests, additionally install `php5-readline` and `phpunit`.
Alternatively, build and install PHP 5.5 or later from source with standard
configuration options.
To also download and install the patched protoc and PHP code generator:
To also download and install protoc and the PHP code generator.
```bash
apt-get install -y procps
curl -sSL https://get.rvm.io | sudo bash -s stable --ruby
git clone sso://team/one-platform-grpc-team/protobuf
git clone git@github.com:google/protobuf.git
cd protobuf
./configure
make
make install
git clone sso://team/one-platform-grpc-team/grpc-php-protobuf-php
cd grpc-php-protobuf-php
git clone git@github.com:murgatroid99/Protobuf-PHP.git
cd Protobuf-PHP
rake pear:package version=1.0
pear install Protobuf-1.0.tgz
```
@ -52,5 +46,4 @@ This repo now has PHPUnit tests, which can by run by executing
There is also a generated code test (`./bin/run_gen_code_test.sh`), which tests
the stub `./tests/generated_code/math.php` against a running localhost server
serving the math service. That stub is generated from
`./tests/generated_code/math.proto` with the head of the repo
`sso://team/one-platform-grpc-team/grpc-php-protobuf-php`.
`./tests/generated_code/math.proto`.

@ -4,8 +4,7 @@ Base GRPC Dockerfile
Dockerfile for creating the base gRPC development Docker instance.
For now, this assumes that the development will be done on GCE instances, with source code on Git-on-Borg.
As of 2014/09/29, it includes
As of 2015/02/02, it includes
- git
- some useful tools like curl, emacs, strace, telnet etc
- downloads the gerrit-compute-tools and installs the script that allows access to gerrit when on git-on-borg
- a patched version of protoc, to allow protos with stream tags to work

@ -5,5 +5,5 @@ Dockerfile for creating the Java development image
As of 2014/12 this
- is based on the gRPC Java base
- pulls from gRPC Java on git-on-borg
- pulls from gRPC Java on GitHub
- installs it and runs the tests

@ -5,6 +5,6 @@ Dockerfile for creating the PHP development instances
As of 2014/10 this
- is based on the GRPC PHP base
- adds a pull of the HEAD GRPC PHP source from git-on-borg
- adds a pull of the HEAD GRPC PHP source from GitHub
- it builds it
- runs the tests, i.e, the image won't be created if the tests don't pass

@ -45,13 +45,9 @@ RUN cd /var/local \
&& ./configure --with-zlib=/usr --with-libxml-dir=ext/libxml \
&& make -j12 && make install
# Start the daemon that allows access to the protected git-on-borg repos
RUN git clone https://gerrit.googlesource.com/gcompute-tools /var/local/git/gcompute-tools
RUN /var/local/git/gcompute-tools/git-cookie-authdaemon
# Download the patched PHP protobuf so that PHP gRPC clients can be generated
# from proto3 schemas.
RUN git clone https://team.googlesource.com/one-platform-grpc-team/grpc-php-protobuf-php /var/local/git/protobuf-php
RUN git clone git@github.com:murgatroid99/Protobuf-PHP.git /var/local/git/protobuf-php
# Install ruby (via RVM) as ruby tools are dependencies for building Protobuf
# PHP extensions.

@ -5,6 +5,6 @@ Dockerfile for creating the Ruby development instances
As of 2014/10 this
- is based on the GRPC Ruby base
- adds a pull of the HEAD gRPC Ruby source from git-on-borg
- adds a pull of the HEAD gRPC Ruby source from GitHub
- it builds it
- runs the tests, i.e, the image won't be created if the tests don't pass

@ -895,7 +895,7 @@ grpc_cloud_prod_gen_java_cmd() {
# constructs the full dockerized php interop test cmd.
#
# TODO(mlumish): update this to use the script once that's on git-on-borg
# TODO(mlumish): update this to use the script once that's on git
#
# call-seq:
# flags= .... # generic flags to include the command

@ -86,7 +86,6 @@ add_instance() {
[[ -n $the_address ]] && address_flag="--address $the_address"
local the_image='container-vm-v20140925'
local scopes='compute-rw storage-full'
scopes+=' https://www.googleapis.com/auth/gerritcodereview'
scopes+=' https://www.googleapis.com/auth/xapi.zoo'
gcloud --project $project compute instances create $instance \
$address_flag \

@ -3,8 +3,7 @@
#
# A grpc-docker GCE machine is based on docker container image.
#
# On startup, it copies the grpc dockerfiles to a local directory, and update its address
# so that the docker containers within it have git-on-borg-access.
# On startup, it copies the grpc dockerfiles to a local directory, and update its address.
# _load_metadata curls a metadata url
_load_metadata() {
@ -54,10 +53,6 @@ main() {
# Install git and emacs
apt-get update && apt-get install -y git emacs || return 1
# Enable access to git repos on git-on-borg
local git_root='/var/local/git'
install_gob_daemon $git_root/gerrit-gcompute-tools || return 1
# Startup the docker registry
grpc_docker_launch_registry && grpc_docker_pull_known

@ -251,37 +251,6 @@ update_address_to() {
}
}
# Allows instances to checkout repos on git-on-borg.
#
install_gob_daemon() {
local gob_dir=$1
[[ -n $gob_dir ]] || { echo "missing args: gob_dir" >&2; return 1; }
local gob_repo=$2
[[ -n $gob_repo ]] || gob_repo='https://gerrit.googlesource.com/gcompute-tools/'
if [[ -e $gob_dir ]]
then
rm -fv $gob_dir || {
echo "could not remove existing git repo at $gob_dir" >&2
return 1
}
fi
git clone $gob_repo $gob_dir || { echo "failed to pull gerrit cookie repo" >&2; return 1; }
local startup_script=/etc/profile.d/gob_cookie_daemon.sh
cat <<EOF >> $startup_script
#!/bin/bash
$gob_dir/git-cookie-authdaemon
EOF
chmod 755 $startup_script
$startup_script
}
# grpc_docker_add_docker_group
#
# Adds a docker group, restarts docker, relaunches the docker registry

Loading…
Cancel
Save