-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ec45dc1
commit b7cdbec
Showing
11 changed files
with
99 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
// For format details, see https://aka.ms/devcontainer.json. | ||
{ | ||
"name": "Resemble Devcontainer", | ||
"image": "ghcr.io/reboot-dev/resemble-devcontainer", | ||
"remoteUser": "dev", | ||
// Features to add to the dev container. More info: https://containers.dev/features. | ||
// "features": {} | ||
// Use 'forwardPorts' to make a list of ports inside the container available locally. | ||
"forwardPorts": [3000, 9991], | ||
// Uncomment the next line to run commands after the container is created. | ||
// "postCreateCommand": "cat /etc/os-release", | ||
// Configure tool-specific properties. | ||
// "customizations": {}, | ||
} | ||
"name": "Resemble Devcontainer", | ||
"image": "ghcr.io/reboot-dev/resemble-devcontainer", | ||
"remoteUser": "dev", | ||
|
||
// Features to add to the dev container. More info: https://containers.dev/features. | ||
// "features": {} | ||
|
||
// Use 'forwardPorts' to make a list of ports inside the container available locally. | ||
"forwardPorts": [3000, 9991] | ||
|
||
// Uncomment the next line to run commands after the container is created. | ||
// "postCreateCommand": "cat /etc/os-release", | ||
|
||
// Configure tool-specific properties. | ||
// "customizations": {}, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,6 +41,4 @@ jobs: | |
uses: devcontainers/[email protected] | ||
with: | ||
runCmd: | | ||
pip install -r ./backend/src/requirements.txt | ||
rsm protoc | ||
pytest backend/ | ||
.tests/test.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,4 +29,4 @@ merge_rules: | |
override_labels: | ||
squash: "" | ||
merge: "" | ||
rebase: mergequeue-rebase | ||
rebase: mergequeue-rebase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#!/bin/bash | ||
|
||
set -e # Exit if a command exits with an error. | ||
set -u # Treat expanding an unset variable as an error. | ||
set -x # Echo executed commands to help debug failures. | ||
|
||
# Check that this script has been invoked with the right working directory, by | ||
# checking that the expected subdirectories exist. | ||
ls -l api/ backend/src/ web/ 2> /dev/null > /dev/null || { | ||
echo "ERROR: this script must be invoked from the root of the 'resemble-hello-world' repository." | ||
echo "Current working directory is '$(pwd)'." | ||
exit 1 | ||
} | ||
|
||
# Create and activate a virtual environment so that we don't pollute the | ||
# system's Python installation. | ||
python -m venv ./.hello-world-venv | ||
source ./.hello-world-venv/bin/activate | ||
|
||
# Use the published Resemble pip packages by default, but allow the test system | ||
# to override them with a different value. | ||
REBOOT_RESEMBLE_PACKAGE=${REBOOT_RESEMBLE_PACKAGE:-"reboot-resemble"} | ||
|
||
# Manually install the Resemble packages before installing the requirements.txt. | ||
# This allows us to install unreleased versions of the Resemble packages during | ||
# tests; the requirements.txt refers to the released versions, but it will skip | ||
# packages that have already been installed. | ||
pip install $REBOOT_RESEMBLE_PACKAGE | ||
|
||
pip install -r backend/src/requirements.txt | ||
|
||
rsm protoc | ||
|
||
pytest backend/ | ||
|
||
# Clean up | ||
rm -rf ./.hello-world-venv |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# This `BUILD.bazel` file allows a `bazel` system (configured outside of this | ||
# repository) to use code in this directory and its subdirectories. | ||
|
||
filegroup( | ||
name = "everything", | ||
srcs = glob( | ||
["**/*"], | ||
exclude = [ | ||
# Folders that may be created by activity in this repository, such | ||
# as manually following the steps of the `README.md` file, but which | ||
# are not part of the "source code" of this repository. | ||
".pytest_cache/**/*", | ||
], | ||
), | ||
visibility = ["//visibility:public"], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
reboot-resemble>=0.0.7 | ||
reboot-resemble>=0.1.0 | ||
pytest>=7.4.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
const { removeModuleScopePlugin, override, babelInclude } = require("customize-cra"); | ||
const { | ||
removeModuleScopePlugin, | ||
override, | ||
babelInclude, | ||
} = require("customize-cra"); | ||
const path = require("path"); | ||
|
||
module.exports = function (config, env) { | ||
|
||
return Object.assign( | ||
config, | ||
override( | ||
removeModuleScopePlugin(), | ||
babelInclude([ | ||
path.resolve('src'), | ||
path.resolve('../api/hello_world/v1'), | ||
]) | ||
)(config, env) | ||
) | ||
} | ||
return Object.assign( | ||
config, | ||
override( | ||
removeModuleScopePlugin(), | ||
babelInclude([path.resolve("src"), path.resolve("../api/hello_world/v1")]) | ||
)(config, env) | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters