Skip to content

Commit

Permalink
Merge pull request #209 from permitio/rename_dockerhub
Browse files Browse the repository at this point in the history
Rename docker hub links + upgrade loguru
  • Loading branch information
asafc authored Jan 31, 2022
2 parents 60e0c09 + 18736f2 commit 6652a35
Show file tree
Hide file tree
Showing 15 changed files with 70 additions and 70 deletions.
30 changes: 15 additions & 15 deletions .github/workflows/on_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@ jobs:
file: docker/Dockerfile
push: false
target: client
cache-from: type=registry,ref=authorizon/opal-client:latest
cache-from: type=registry,ref=permitio/opal-client:latest
cache-to: type=inline
load: true
tags: |
authorizon/opal-client:test
authorizon/opal-client:latest
authorizon/opal-client:${{ env.opal_version_tag }}
permitio/opal-client:test
permitio/opal-client:latest
permitio/opal-client:${{ env.opal_version_tag }}
- name: Build client-standalone
id: build_client_standalone
Expand All @@ -78,13 +78,13 @@ jobs:
file: docker/Dockerfile
push: false
target: client-standalone
cache-from: type=registry,ref=authorizon/opal-client-standalone:latest
cache-from: type=registry,ref=permitio/opal-client-standalone:latest
cache-to: type=inline
load: true
tags: |
authorizon/opal-client-standalone:test
authorizon/opal-client-standalone:latest
authorizon/opal-client-standalone:${{ env.opal_version_tag }}
permitio/opal-client-standalone:test
permitio/opal-client-standalone:latest
permitio/opal-client-standalone:${{ env.opal_version_tag }}
- name: Build server
id: build_server
Expand All @@ -93,13 +93,13 @@ jobs:
file: docker/Dockerfile
push: false
target: server
cache-from: type=registry,ref=authorizon/opal-server:latest
cache-from: type=registry,ref=permitio/opal-server:latest
cache-to: type=inline
load: true
tags: |
authorizon/opal-server:test
authorizon/opal-server:latest
authorizon/opal-server:${{ env.opal_version_tag }}
permitio/opal-server:test
permitio/opal-server:latest
permitio/opal-server:${{ env.opal_version_tag }}
# TEST PHASE
- name: Create modified docker compose file
Expand Down Expand Up @@ -129,12 +129,12 @@ jobs:
# each image is pushed with the versioned tag first, if it succeeds the image is pushed with the latest tag as well.
- name: Push client
if: ${{ !(github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run == 'true') }}
run: docker push authorizon/opal-client:${{ env.opal_version_tag }} && docker push authorizon/opal-client:latest
run: docker push permitio/opal-client:${{ env.opal_version_tag }} && docker push permitio/opal-client:latest

- name: Push client-standalone
if: ${{ !(github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run == 'true') }}
run: docker push authorizon/opal-client-standalone:${{ env.opal_version_tag }} && docker push authorizon/opal-client-standalone:latest
run: docker push permitio/opal-client-standalone:${{ env.opal_version_tag }} && docker push permitio/opal-client-standalone:latest

- name: Push server
if: ${{ !(github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run == 'true') }}
run: docker push authorizon/opal-server:${{ env.opal_version_tag }} && docker push authorizon/opal-server:latest
run: docker push permitio/opal-server:${{ env.opal_version_tag }} && docker push permitio/opal-server:latest
22 changes: 11 additions & 11 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -39,41 +39,41 @@ install-server-from-src:

# docker
docker-build-client:
@docker build -t authorizon/opal-client --target client -f docker/Dockerfile .
@docker build -t permitio/opal-client --target client -f docker/Dockerfile .

docker-build-client-standalone:
@docker build -t authorizon/opal-client-standalone --target client-standalone -f docker/Dockerfile .
@docker build -t permitio/opal-client-standalone --target client-standalone -f docker/Dockerfile .

docker-run-client:
@docker run -it -e "OPAL_SERVER_URL=$(OPAL_SERVER_URL)" -p 7000:7000 -p 8181:8181 authorizon/opal-client
@docker run -it -e "OPAL_SERVER_URL=$(OPAL_SERVER_URL)" -p 7000:7000 -p 8181:8181 permitio/opal-client

docker-run-client-standalone:
@docker run -it \
-e "OPAL_SERVER_URL=$(OPAL_SERVER_URL)" \
-e "OPAL_POLICY_STORE_URL=$(OPAL_POLICY_STORE_URL)" \
-p 7000:7000 \
authorizon/opal-client-standalone
permitio/opal-client-standalone

docker-build-server:
@docker build -t authorizon/opal-server --target server -f docker/Dockerfile .
@docker build -t permitio/opal-server --target server -f docker/Dockerfile .

docker-build-next:
@docker build -t authorizon/opal-client-standalone:next --target client-standalone -f docker/Dockerfile .
@docker build -t authorizon/opal-client:next --target client -f docker/Dockerfile .
@docker build -t authorizon/opal-server:next --target server -f docker/Dockerfile .
@docker build -t permitio/opal-client-standalone:next --target client-standalone -f docker/Dockerfile .
@docker build -t permitio/opal-client:next --target client -f docker/Dockerfile .
@docker build -t permitio/opal-server:next --target server -f docker/Dockerfile .

docker-run-server:
@if [[ -z "$(OPAL_POLICY_REPO_SSH_KEY)" ]]; then \
docker run -it \
-e "OPAL_POLICY_REPO_URL=$(OPAL_POLICY_REPO_URL)" \
-p 7002:7002 \
authorizon/opal-server; \
permitio/opal-server; \
else \
docker run -it \
-e "OPAL_POLICY_REPO_URL=$(OPAL_POLICY_REPO_URL)" \
-e "OPAL_POLICY_REPO_SSH_KEY=$(OPAL_POLICY_REPO_SSH_KEY)" \
-p 7002:7002 \
authorizon/opal-server; \
permitio/opal-server; \
fi

docker-run-server-secure:
Expand All @@ -83,4 +83,4 @@ docker-run-server-secure:
-e "OPAL_AUTH_PUBLIC_KEY=$(OPAL_AUTH_PUBLIC_KEY)" \
-e "OPAL_POLICY_REPO_URL=$(OPAL_POLICY_REPO_URL)" \
-p 7002:7002 \
authorizon/opal-server
permitio/opal-server
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ Open Policy Administration Layer
<img src="https://static.pepy.tech/personalized-badge/opal-server?period=total&units=international_system&left_color=black&right_color=blue&left_text=Downloads" alt="Downloads">
</a>

<a href="https://hub.docker.com/r/authorizon/opal-server" target="_blank">
<img src="https://img.shields.io/docker/pulls/authorizon/opal-server?label=Docker%20pulls" alt="Docker pulls">
<a href="https://hub.docker.com/r/permitio/opal-server" target="_blank">
<img src="https://img.shields.io/docker/pulls/permitio/opal-server?label=Docker%20pulls" alt="Docker pulls">
</a>

<a href="https://opal-access.slack.com/" target="_blank">
Expand All @@ -38,21 +38,21 @@ As your application state changes (whether it's via your APIs, DBs, git, S3 or 3
Check out our main site at <a href="https://opal.ac">OPAL.ac</a> and <a href="https://youtu.be/tG8jrdcc7Zo">this video</a> briefly explaining OPAL and how it works with OPA.

## Why use OPAL?
OPAL is the easiest way to keep your solution's authorization layer up-to-date in realtime. It aggregates policy and data from across the field and integrates them seamlessly into the authorization layer, and is microservices and cloud-native.
OPAL is the easiest way to keep your solution's authorization layer up-to-date in realtime. It aggregates policy and data from across the field and integrates them seamlessly into the authorization layer, and is microservices and cloud-native.

## OPA + OPAL = 💜
While OPA (Open Policy Agent) decouples policy from code in a highly-performant and elegant way, the challenge of keeping policy agents up-to-date remains.
While OPA (Open Policy Agent) decouples policy from code in a highly-performant and elegant way, the challenge of keeping policy agents up-to-date remains.
This is especially true in applications, where each user interaction or API call may affect access-control decisions.
OPAL runs in the background, supercharging policy-agents, keeping them in sync with events in realtime.

## Documentation
## Documentation

- 📃 &nbsp; [Full documentation is available here](docs/index.md)
- 💡 &nbsp; [Intro to OPAL](docs/intro.md)
- 📃 &nbsp; [Full documentation is available here](docs/index.md)
- 💡 &nbsp; [Intro to OPAL](docs/intro.md)
- 🚀 &nbsp; Getting Started:

OPAL is available both as **python packages** with a built-in CLI as well as pre-built **docker images** ready-to-go.

- [Play with a live playground environment in docker-compose](docs/HOWTO/get_started_with_opal_docker_compose_tutorial.md)
<!-- - this tutorial is great for learning about OPAL core features and see what OPAL can do for you. -->
- [Try the getting started guide for containers](docs/HOWTO/get_started_with_opal_using_docker.md)
Expand Down Expand Up @@ -88,8 +88,8 @@ curl -L https://raw.githubusercontent.com/permitio/opal/master/docker/docker-com
- [How to configure OPAL (basic concepts)](docs/HOWTO/configure_opal.md)


- 🎨 &nbsp; [Key concepts and design](docs/design.md)
- 🏗️ &nbsp; [Architecture](docs/architecture.md)
- 🎨 &nbsp; [Key concepts and design](docs/design.md)
- 🏗️ &nbsp; [Architecture](docs/architecture.md)

OPAL uses a client-server stateless architecture. OPAL-Servers publish policy and data updates over a lightweight (websocket) PubSub Channel, which OPAL-clients subscribe to via topics. Upon updates each client fetches data directly (from source) to load it in to its managed OPA instance.
<br>
Expand Down Expand Up @@ -119,7 +119,7 @@ If you are using our project, please consider giving us a ⭐️

## Contributing to OPAL
- Pull requests are welcome! (please make sure to include *passing* tests and docs)
- Prior to submitting a PR - open an issue on GitHub, or make sure your PR addresses an existing issue well.
- Prior to submitting a PR - open an issue on GitHub, or make sure your PR addresses an existing issue well.

[join-slack-link]: https://i.ibb.co/wzrGHQL/Group-749.png
[badge-slack-link]: https://bit.ly/opal-slack
Expand Down
4 changes: 2 additions & 2 deletions docker/docker-compose-api-policy-source-example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ services:

opal_server:
# by default we run opal-server from latest official image
image: authorizon/opal-server:latest
image: permitio/opal-server:latest
environment:
# the broadcast backbone uri used by opal server workers (see comments above for: broadcast_channel)
- OPAL_BROADCAST_URI=postgres://postgres:postgres@broadcast_channel:5432/postgres
Expand Down Expand Up @@ -47,7 +47,7 @@ services:

opal_client:
# by default we run opal-client from latest official image
image: authorizon/opal-client:latest
image: permitio/opal-client:latest
environment:
- OPAL_SERVER_URL=http://opal_server:7002
- OPAL_LOG_FORMAT_INCLUDE_PID=true
Expand Down
4 changes: 2 additions & 2 deletions docker/docker-compose-example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- POSTGRES_PASSWORD=postgres
opal_server:
# by default we run opal-server from latest official image
image: authorizon/opal-server:latest
image: permitio/opal-server:latest
environment:
# the broadcast backbone uri used by opal server workers (see comments above for: broadcast_channel)
- OPAL_BROADCAST_URI=postgres://postgres:postgres@broadcast_channel:5432/postgres
Expand All @@ -41,7 +41,7 @@ services:
- broadcast_channel
opal_client:
# by default we run opal-client from latest official image
image: authorizon/opal-client:latest
image: permitio/opal-client:latest
environment:
- OPAL_SERVER_URL=http://opal_server:7002
- OPAL_LOG_FORMAT_INCLUDE_PID=true
Expand Down
4 changes: 2 additions & 2 deletions docker/docker-compose-with-callbacks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- POSTGRES_PASSWORD=postgres
opal_server:
# by default we run opal-server from latest official image
image: authorizon/opal-server:latest
image: permitio/opal-server:latest
environment:
# the broadcast backbone uri used by opal server workers (see comments above for: broadcast_channel)
- OPAL_BROADCAST_URI=postgres://postgres:postgres@broadcast_channel:5432/postgres
Expand All @@ -41,7 +41,7 @@ services:
- broadcast_channel
opal_client:
# by default we run opal-client from latest official image
image: authorizon/opal-client:latest
image: permitio/opal-client:latest
environment:
- OPAL_SERVER_URL=http://opal_server:7002
- OPAL_LOG_FORMAT_INCLUDE_PID=true
Expand Down
4 changes: 2 additions & 2 deletions docker/docker-compose-with-security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ services:
- POSTGRES_PASSWORD=postgres
opal_server:
# by default we run opal-server from latest official image
image: authorizon/opal-server:latest
image: permitio/opal-server:latest
environment:
# the broadcast backbone uri used by opal server workers (see comments above for: broadcast_channel)
- OPAL_BROADCAST_URI=postgres://postgres:postgres@broadcast_channel:5432/postgres
Expand Down Expand Up @@ -63,7 +63,7 @@ services:
- broadcast_channel
opal_client:
# by default we run opal-client from latest official image
image: authorizon/opal-client:latest
image: permitio/opal-client:latest
environment:
- OPAL_SERVER_URL=http://opal_server:7002
- OPAL_CLIENT_TOKEN=${OPAL_CLIENT_TOKEN}
Expand Down
4 changes: 2 additions & 2 deletions docker/docker-compose-with-statistics.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- POSTGRES_PASSWORD=postgres
opal_server:
# by default we run opal-server from latest official image
image: authorizon/opal-server:latest
image: permitio/opal-server:latest
environment:
# the broadcast backbone uri used by opal server workers (see comments above for: broadcast_channel)
- OPAL_BROADCAST_URI=postgres://postgres:postgres@broadcast_channel:5432/postgres
Expand Down Expand Up @@ -43,7 +43,7 @@ services:
- broadcast_channel
opal_client:
# by default we run opal-client from latest official image
image: authorizon/opal-client:latest
image: permitio/opal-client:latest
environment:
- OPAL_SERVER_URL=http://opal_server:7002
- OPAL_LOG_FORMAT_INCLUDE_PID=true
Expand Down
4 changes: 2 additions & 2 deletions docs/HOWTO/get_started_with_opal_docker_compose_tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ This entire tutorial is also recorded here:
This one command will download and run a working configuration of OPAL server and OPAL client on your machine:

```
curl -L https://raw.githubusercontent.com/authorizon/opal/master/docker/docker-compose-example.yml \
curl -L https://raw.githubusercontent.com/permitio/opal/master/docker/docker-compose-example.yml \
> docker-compose.yml && docker-compose up
```

Expand Down Expand Up @@ -237,7 +237,7 @@ Let's review what they are and their main functions:
#### (3) OPAL Client

- **Can run OPA for you (inline process)**
- The OPAL-Client [docker image](https://hub.docker.com/r/authorizon/opal-client) contains a built-in OPA agent, and can serve as fully-functional **authorization microservice**. OPA is solely responsible for enforcement (evaluates authorization queries) and OPAL is solely responsible for state-management (keeps the policy and data needed to evaluate queries up-to-date).
- The OPAL-Client [docker image](https://hub.docker.com/r/permitio/opal-client) contains a built-in OPA agent, and can serve as fully-functional **authorization microservice**. OPA is solely responsible for enforcement (evaluates authorization queries) and OPAL is solely responsible for state-management (keeps the policy and data needed to evaluate queries up-to-date).
- In our example `docker-compose.yml` OPA is enabled and runs on port `:8181`, exposed on the host machine.
- OPAL will manage the OPA process. If the OPA process fails for some reason (unlikely :)), OPAL will restart OPA and rehydrate the OPA cache with valid and up-to-date state (i.e: will re-download policies and data).
- **Syncs OPA with latest policy code**
Expand Down
28 changes: 14 additions & 14 deletions docs/HOWTO/get_started_with_opal_using_docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Our recommendation is to start with the [docker-compose playground](https://gith
</tr>
<tr>
<td valign="top"><a href="https://hub.docker.com/r/permitio/opal-server">OPAL Server</a></td>
<td valign="top"><code>docker pull authorizon/opal-server</code></td>
<td valign="top"><code>docker pull permitio/opal-server</code></td>
<td valign="top">
<ul>
<li>Creates a Pub/Sub channel clients subscribe to</li>
Expand All @@ -63,7 +63,7 @@ Our recommendation is to start with the [docker-compose playground](https://gith
</tr>
<tr>
<td valign="top"><a href="https://hub.docker.com/r/permitio/opal-client">OPAL Client</a></td>
<td valign="top"><code>docker pull authorizon/opal-client</code></td>
<td valign="top"><code>docker pull permitio/opal-client</code></td>
<td valign="top">
<ul>
<li>Prebuilt with an OPA agent inside the image</li>
Expand All @@ -74,8 +74,8 @@ Our recommendation is to start with the [docker-compose playground](https://gith
</td>
</tr>
<tr>
<td valign="top"><a href="https://hub.docker.com/r/authorizon/opal-client">OPAL Client (Standalone)</a></td>
<td valign="top"><code>docker pull authorizon/opal-client-standalone</code></td>
<td valign="top"><a href="https://hub.docker.com/r/permitio/opal-client">OPAL Client (Standalone)</a></td>
<td valign="top"><code>docker pull permitio/opal-client-standalone</code></td>
<td valign="top">
<ul>
<li><strong>Same as OPAL Client, you want only one of them</strong></li>
Expand Down Expand Up @@ -110,7 +110,7 @@ docker run -it \
-e "OPAL_AUTH_PUBLIC_KEY=$(OPAL_AUTH_PUBLIC_KEY)" \
-e "OPAL_POLICY_REPO_URL=$(OPAL_POLICY_REPO_URL)" \
-p 7002:7002 \
authorizon/opal-server
permitio/opal-server
```
This command | In production environments
:--- | :---
Expand Down Expand Up @@ -152,9 +152,9 @@ If you run the docker image locally, you need docker installed on your machine.

Run this command to get the image:
```
docker pull authorizon/opal-server
docker pull permitio/opal-server
```
If you run in a cloud environment (e.g: AWS ECS), specify `authorizon/opal-server` in your task definition or equivalent.
If you run in a cloud environment (e.g: AWS ECS), specify `permitio/opal-server` in your task definition or equivalent.

Running the opal server container is simply a command of [docker run](#example-docker-run), but we need to pipe to the OPAL server container the neccessary configration it needs via **environment variables**. The following sections will explain each class of configuration variables and how to set their values, after which we will demonstrate real examples.

Expand Down Expand Up @@ -498,7 +498,7 @@ We will now recap with a real example.

#### 1) Pull the server container image
```
docker pull authorizon/opal-server
docker pull permitio/opal-server
```

#### 2) Define the environment variables you need
Expand Down Expand Up @@ -543,7 +543,7 @@ docker run -it \
--env OPAL_AUTH_PUBLIC_KEY \
--env OPAL_AUTH_MASTER_TOKEN \
-p 7002:7002 \
authorizon/opal-server
permitio/opal-server
```

#### 4) <a name="run-docker-prod"></a> Run the container in production
Expand All @@ -565,14 +565,14 @@ Great! we have OPAL Server up and running. Let's continue and explains how to ru
#### Running with inline OPA (default / recommended)
Run this command to get the image that comes with built-in OPA (recommended if you don't already have OPA installed in your environment):
```
docker pull authorizon/opal-client
docker pull permitio/opal-client
```
If you run in a cloud environment (e.g: AWS ECS), specify `authorizon/opal-client` in your task definition or equivalent.
If you run in a cloud environment (e.g: AWS ECS), specify `permitio/opal-client` in your task definition or equivalent.

#### Running with standalone OPA
Otherwise, if you are already running OPA in your environment, run this command to get the standalone client image instead:
```
docker pull authorizon/opal-client-standalone
docker pull permitio/opal-client-standalone
```

### Step 2: Obtain client JWT token (Optional)
Expand Down Expand Up @@ -691,7 +691,7 @@ Let's recap the previous steps with example values:
#### 1) Get the client image
First, download opal client docker image:
```sh
docker pull authorizon/opal-client
docker pull permitio/opal-client
```

#### 2) Set configuration
Expand All @@ -716,7 +716,7 @@ docker run -it \
--env OPAL_DATA_TOPICS \
-p 7000:7000 \
-p 8181:8181 \
authorizon/opal-client
permitio/opal-client
```

Please notice opal client exposes two ports when running opa inline:
Expand Down
Loading

0 comments on commit 6652a35

Please sign in to comment.