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
sudo dnf install rpmbuild | |
No match for argument: rpmbuild | |
Error: Unable to find a match: rpmbuild |
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
npm run make | |
> electron-github@1.0.0 make /home/austincunningham/repo/electron-github | |
> electron-forge make | |
✔ Checking your system | |
✔ Resolving Forge Config | |
An unhandled rejection has occurred inside Forge: | |
Error: Cannot make for rpm, the following external binaries need to be installed: rpmbuild |
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
npm run make | |
> electron-github@1.0.0 make /home/austincunningham/repo/electron-github | |
> electron-forge make | |
✔ Checking your system | |
✔ Resolving Forge Config | |
An unhandled rejection has occurred inside Forge: | |
Error: Cannot make for deb, the following external binaries need to be installed: dpkg, fakeroot |
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
const { app, BrowserWindow } = require('electron') | |
const path = require('path') | |
const createWindow = () => { | |
const win = new BrowserWindow({ | |
width: 1200, | |
height: 850, | |
webPreferences: { | |
preload: path.join(__dirname, 'preload.js') | |
} |
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
# get the service | |
oc get service | |
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE | |
podroute-service ClusterIP 10.217.5.14 <none> 8080/TCP 4m38s | |
# get the route | |
oc get route | |
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD | |
podroute-route podroute-route-podroute.apps-crc.testing podroute-service 8080 None | |
# should be 3 pod replicas | |
oc get pods |
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
oc login -u kubeadmin -p KUBEADMIN_PASSWORD https://api.crc.testing:6443 | |
oc new-project podroute | |
# Installs the custom resource definitions onto the cluster | |
make install | |
# Create the CR on cluster | |
oc apply -f - <<EOF | |
--- | |
apiVersion: quay.io/v1alpha1 | |
kind: Podroute | |
metadata: |
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
crc start | |
INFO Adding crc-admin and crc-developer contexts to kubeconfig... | |
Started the OpenShift cluster. | |
The server is accessible via web console at: | |
https://console-openshift-console.apps-crc.testing | |
Log in as administrator: | |
Username: kubeadmin | |
Password: KUBEADMIN_PASSWORD |
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
if err := routev1.AddToScheme(mgr.GetScheme()); err != nil { | |
setupLog.Error(err, "failed to add routev1 to scheme") | |
os.Exit(1) | |
} |
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
import ( | |
"context" | |
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" | |
"k8s.io/apimachinery/pkg/types" | |
"k8s.io/apimachinery/pkg/util/intstr" | |
"sigs.k8s.io/controller-runtime/pkg/controller/controllerutil" | |
"sigs.k8s.io/controller-runtime/pkg/reconcile" | |
routev1 "github.com/openshift/api/route/v1" | |
appsv1 "k8s.io/api/apps/v1" |
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
// check for a route if it doesn't exist it creates one on cluster using the route created in podRouteRoute | |
func (r PodrouteReconciler) createRoute(cr *quayiov1alpha1.Podroute, podRouteRoute *routev1.Route) error { | |
// check for a route in the namespace | |
found := &routev1.Route{} | |
err := r.Client.Get(context.TODO(), types.NamespacedName{Name: podRouteRoute.Name, Namespace: cr.Namespace}, found) | |
if err != nil { | |
log.Log.Info("Creating Route") | |
err = r.Client.Create(context.TODO(), podRouteRoute) | |
if err != nil { | |
log.Log.Error(err, "Failed to create Route") |